mirror of
https://github.com/django/django.git
synced 2025-07-19 03:05:32 +00:00
[py3] Replaced unicode/str by six.text_type/bytes.
This commit is contained in:
parent
3cb2457f46
commit
bdca5ea345
96 changed files with 376 additions and 294 deletions
|
@ -265,7 +265,7 @@ class FileField(Field):
|
|||
# Need to convert File objects provided via a form to unicode for database insertion
|
||||
if value is None:
|
||||
return None
|
||||
return unicode(value)
|
||||
return six.text_type(value)
|
||||
|
||||
def pre_save(self, model_instance, add):
|
||||
"Returns field's value just before saving."
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue