Modify ↓
Opened 14 years ago
Closed 14 years ago
#8503 closed defect (fixed)
Cannot use all as file extenstion
Reported by: | anonymous | Owned by: | Radek Bartoň |
---|---|---|---|
Priority: | normal | Component: | DownloadsPlugin |
Severity: | normal | Keywords: | |
Cc: | Trac Release: | 0.12 |
Description
I would like to allow download of all files, no matter extension.
I can see in code that there is a special treatment of 'all' extension. Intention was probably to allow all downloads if all was configured.
But, as it is implemented, if all is added to the list of allowed extensions, all uploads are denied
api.py:
791 name, ext = os.path.splitext(download['file']) 792 if not 'all' in self.ext: 793 self.log.debug('file_ext: %s ext: %s' % (ext, self.ext)) 794 if not ext[1:].lower() in self.ext: 795 raise TracError('Unsupported file type.') 796 else: 797 raise TracError('Unsupported file type.')
If 796-797 are removed, it should work as intended, i.e. if all is in list, all extensions are allowed.
Attachments (0)
Note: See
TracTickets for help on using
tickets.
Fixed in r10047.