Skip to content
Snippets Groups Projects
Commit 3413fe48 authored by sandeepsajan0's avatar sandeepsajan0
Browse files

fix: Add anyascii to remove unidecode as per wagtail-2.11 documentation

parent bef36944
No related branches found
No related tags found
No related merge requests found
......@@ -11,7 +11,7 @@ from django.utils.html import conditional_escape
from django.utils.text import slugify
from django.utils.translation import gettext_lazy as _
from django_bleach.templatetags.bleach_tags import bleach_value
from unidecode import unidecode
from anyascii import anyascii
from wagtail.core.blocks import (
BooleanBlock,
CharBlock,
......@@ -44,7 +44,7 @@ class FormFieldBlock(StructBlock):
template = 'stream_forms/render_field.html'
def get_slug(self, struct_value):
return force_str(slugify(unidecode(struct_value['field_label'])))
return force_str(slugify(anyascii(struct_value['field_label'])))
def get_field_class(self, struct_value):
return self.field_class
......
......@@ -46,3 +46,4 @@ wagtail-cache==1.0.1
wagtail-purge==0.1
wagtail==2.13
whitenoise==5.2.0
anyascii==0.2.0
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment