Skip to content

Commit 6b11dec

Browse files
authored
[fix] hash check (#54)
1 parent f05169f commit 6b11dec

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

crud.py

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,11 +143,20 @@ async def create_hash_check(the_hash: str, lnurl_id: str) -> HashCheck:
143143

144144

145145
async def get_hash_check(the_hash: str, lnurl_id: str) -> HashCheck:
146+
146147
hash_check = await db.fetchone(
147-
"SELECT * FROM withdraw.hash_check WHERE id = :id", {"id": the_hash}, HashCheck
148+
"""
149+
SELECT id as hash, lnurl_id as lnurl
150+
FROM withdraw.hash_check WHERE id = :id
151+
""",
152+
{"id": the_hash},
153+
HashCheck,
148154
)
149155
hash_check_lnurl = await db.fetchone(
150-
"SELECT * FROM withdraw.hash_check WHERE lnurl_id = :id",
156+
"""
157+
SELECT id as hash, lnurl_id as lnurl
158+
FROM withdraw.hash_check WHERE lnurl_id = :id
159+
""",
151160
{"id": lnurl_id},
152161
HashCheck,
153162
)

0 commit comments

Comments
 (0)