0001-mdel-ignore-case-when-searching-for-response-files-2.patch
passerelle/contrib/mdel/models.py | ||
---|---|---|
320 | 320 |
output_dir = os.path.join(resource_base_dir, self.resource.slug, |
321 | 321 |
'outputs') |
322 | 322 | |
323 |
zfiles = [zfile for zfile in os.listdir(output_dir) |
|
324 |
if zfile.startswith(self.demand_id) and zfile.endswith('.zip')] |
|
323 |
# search demand response zip file |
|
324 |
# without caring about the case |
|
325 |
zfiles = [] |
|
326 |
for zfile in os.listdir(output_dir): |
|
327 |
if zfile.lower().startswith(self.demand_id.lower()) and zfile.lower().endswith('.zip'): |
|
328 |
zfiles.append(zfile) |
|
325 | 329 | |
326 | 330 |
def fnum(zfile): |
327 | 331 |
"""Returns response's file number |