minor: fix indentation
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
This commit is contained in:
parent
d0cb96781c
commit
cb6790b804
@ -56,7 +56,8 @@ class LocalStatusSQLiteFolder(BaseFolder):
|
||||
if not os.path.exists(dirname):
|
||||
os.makedirs(dirname)
|
||||
if not os.path.isdir(dirname):
|
||||
raise UserWarning("SQLite database path '%s' is not a directory." % dirname)
|
||||
raise UserWarning("SQLite database path '%s' is not a directory."%
|
||||
dirname)
|
||||
|
||||
# dblock protects against concurrent writes in same connection
|
||||
self._dblock = Lock()
|
||||
@ -74,7 +75,8 @@ class LocalStatusSQLiteFolder(BaseFolder):
|
||||
|
||||
#Test if db version is current enough and if db is readable.
|
||||
try:
|
||||
cursor = self.connection.execute("SELECT value from metadata WHERE key='db_version'")
|
||||
cursor = self.connection.execute(
|
||||
"SELECT value from metadata WHERE key='db_version'")
|
||||
except sqlite.DatabaseError:
|
||||
#db file missing or corrupt, recreate it.
|
||||
self.__create_db()
|
||||
|
Loading…
Reference in New Issue
Block a user