stars fixes

This commit is contained in:
user committed 2025-03-01 14:01:00 +03:00
1 parent 10cb581b34
commit 79593f1e75
2 files changed
+3 -3

No files matched your search

+2 -2
View File
@@ -86,13 +86,13 @@ async def s_api_v1_content_view(request, content_address: str):
StarsInvoice.user_id == request.ctx.user.id,
StarsInvoice.created > datetime.now() - timedelta(minutes=25),
StarsInvoice.amount == stars_cost,
StarsInvoice.external_id == invoice_id
StarsInvoice.content_hash == content['encrypted_content'].hash,
)
).first()
if exist_invoice:
invoice_url = exist_invoice.invoice_url
else:
invocie_url = None
invoice_url = None
try:
invoice_url = await Bot(token=CLIENT_TELEGRAM_API_KEY).create_invoice_link(
'Lifetime access to content',