Fixed invalid variable name

pull/892/head
Piero Toffanin 2020-07-26 12:39:10 -04:00
rodzic 6b323c2086
commit f28c0f3a0d
1 zmienionych plików z 1 dodań i 1 usunięć

Wyświetl plik

@ -98,7 +98,7 @@ class File:
def is_valid(self):
"""Only keep files that are images, or that are named 'gcp_list.txt'"""
_, file_extension = path.splitext(self.name)
return file_extension.lower() in VALID_IMAGE_EXTENSIONS or file_name == 'gcp_list.txt'
return file_extension.lower() in VALID_IMAGE_EXTENSIONS or self.name == 'gcp_list.txt'
def serialize(self):
return {'name': self.name, 'url': self.url}