mirror of
https://github.com/django/django.git
synced 2025-07-19 03:05:32 +00:00
Removed an inactive system check for upload_to.
Thanks to Simon Charette for the eagle eyes.
This commit is contained in:
parent
be8173af51
commit
a029efca44
2 changed files with 0 additions and 30 deletions
|
@ -238,24 +238,10 @@ class FileField(Field):
|
|||
|
||||
def check(self, **kwargs):
|
||||
errors = super(FileField, self).check(**kwargs)
|
||||
#errors.extend(self._check_upload_to())
|
||||
errors.extend(self._check_unique())
|
||||
errors.extend(self._check_primary_key())
|
||||
return errors
|
||||
|
||||
def _check_upload_to(self):
|
||||
if not self.upload_to:
|
||||
return [
|
||||
checks.Error(
|
||||
'The field requires an "upload_to" attribute.',
|
||||
hint=None,
|
||||
obj=self,
|
||||
id='E031',
|
||||
)
|
||||
]
|
||||
else:
|
||||
return []
|
||||
|
||||
def _check_unique(self):
|
||||
if self._unique_set_explicitly:
|
||||
return [
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue