Skip to content

[BugFix] add "allow_unicode" option to ModelSerializer SlugField#6315

Merged
carltongibson merged 1 commit intoencode:masterfrom
naihe2010:master
Dec 19, 2018
Merged

[BugFix] add "allow_unicode" option to ModelSerializer SlugField#6315
carltongibson merged 1 commit intoencode:masterfrom
naihe2010:master

Conversation

@naihe2010
Copy link
Copy Markdown
Contributor

If a SlugField set allow_unicode, the ModelSelializer have not set it.
when user create/update a model, the validator will reject the unicode slug field.
So, this fix add this option in field mapping.

Copy link
Copy Markdown
Collaborator

@carltongibson carltongibson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep. This looks good. allow_unicode was added in Django 1.9.

@carltongibson carltongibson added this to the 3.9.1 Release milestone Dec 19, 2018
@carltongibson carltongibson merged commit 963ce30 into encode:master Dec 19, 2018
pchiquet pushed a commit to pchiquet/django-rest-framework that referenced this pull request Nov 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants