Fix bug with validating filenames from args in GUI

This commit is contained in:
Micah Lee 2018-03-14 08:34:43 -07:00
parent fee1d49563
commit 929ad58ebd
No known key found for this signature in database
GPG key ID: 403C2657CD994F73

View file

@ -92,10 +92,10 @@ def main():
valid = True
for filename in filenames:
if not os.path.isfile(filename) and not os.path.isdir(filename):
Alert(self.common, strings._("not_a_file", True).format(filename))
Alert(common, strings._("not_a_file", True).format(filename))
valid = False
if not os.access(filename, os.R_OK):
Alert(self.common, strings._("not_a_readable_file", True).format(filename))
Alert(common, strings._("not_a_readable_file", True).format(filename))
valid = False
if not valid:
sys.exit()