fix fetch_unpacked row factory
This commit is contained in:
parent
11e0b05be1
commit
38e41dc1b5
1 changed files with 2 additions and 2 deletions
|
@ -112,8 +112,8 @@ def unpack(lst_of_tpl):
|
|||
|
||||
|
||||
async def fetch_unpacked(db, sql, params=None):
|
||||
cur = db.cursor()
|
||||
cur.row_factory = first
|
||||
cur = await db.cursor()
|
||||
cur.row_factory = lambda cursor, row: first(row)
|
||||
cur = await cur.execute(sql, params)
|
||||
return await cur.fetchall()
|
||||
|
||||
|
|
Loading…
Reference in a new issue