Merge pull request #488 from mcarlton00/pls-mr-linter

Fix formatting on multiline if statement
This commit is contained in:
mcarlton00 2021-03-14 21:40:28 -04:00 committed by GitHub
commit b3e88bbeb2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -116,9 +116,10 @@ class Database(object):
target = {'db_file': '', 'version': 0} target = {'db_file': '', 'version': 0}
for db_file in reversed(files): for db_file in reversed(files):
if (db_file.startswith(database) and not db_file.endswith('-wal') if (db_file.startswith(database)
and not db_file.endswith('-shm') and not db_file.endswith('-wal')
and not db_file.endswith('db-journal')): and not db_file.endswith('-shm')
and not db_file.endswith('db-journal')):
version_string = re.search('{}(.*).db'.format(database), db_file) version_string = re.search('{}(.*).db'.format(database), db_file)
version = int(version_string.group(1)) version = int(version_string.group(1))