Removed a redundant directory join during FileField form saving. Thanks to David Danier's eagle eyes for picking up this one.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5826 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
f1edb8c2b3
commit
a49fd11055
|
@ -784,7 +784,7 @@ class FileField(Field):
|
||||||
|
|
||||||
def save_form_data(self, instance, data):
|
def save_form_data(self, instance, data):
|
||||||
if data:
|
if data:
|
||||||
getattr(instance, "save_%s_file" % self.name)(os.path.join(self.upload_to, data.filename), data.content, save=False)
|
getattr(instance, "save_%s_file" % self.name)(data.filename, data.content, save=False)
|
||||||
|
|
||||||
def formfield(self, **kwargs):
|
def formfield(self, **kwargs):
|
||||||
defaults = {'form_class': forms.FileField}
|
defaults = {'form_class': forms.FileField}
|
||||||
|
|
Loading…
Reference in New Issue