Ticket #4776: strftime_unicode.diff

File strftime_unicode.diff, 637 bytes (added by anonymous, 8 years ago)
  • db/models/fields/__init__.py

     
    735735                func(new_data[upload_field_name]["filename"], new_data[upload_field_name]["content"], save)
    736736
    737737    def get_directory_name(self):
    738         return os.path.normpath(datetime.datetime.now().strftime(self.upload_to))
     738        return os.path.normpath(datetime.datetime.now().strftime(str(self.upload_to)))
    739739
    740740    def get_filename(self, filename):
    741741        from django.utils.text import get_valid_filename
Back to Top