Skip to content

Commit

Permalink
chore: Apply fix from #80 user settings table creation.
Browse files Browse the repository at this point in the history
  • Loading branch information
osala-eng committed Sep 12, 2023
1 parent 2f2be4c commit 63125e8
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions source/docq/manage_settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,7 @@ def _get_sqlite_file(user_id: int = None) -> str:
def _get_settings(user_id: int = None) -> dict:
log.debug("Getting settings for user %s", str(user_id))
with closing(
# sqlite3.connect(_get_sqlite_file(user_id), detect_types=sqlite3.PARSE_DECLTYPES)
sqlite3.connect(_get_sqlite_file(), detect_types=sqlite3.PARSE_DECLTYPES) # FIXME: fix sqlite3.OperationalError: no such table: settings if user_id is not None
sqlite3.connect(_get_sqlite_file(user_id), detect_types=sqlite3.PARSE_DECLTYPES)
) as connection, closing(connection.cursor()) as cursor:
id_ = user_id or USER_ID_AS_SYSTEM
rows = cursor.execute(
Expand Down

0 comments on commit 63125e8

Please sign in to comment.