mirror of
https://github.com/bohd4nx/FragmentAPI.git
synced 2026-07-25 14:24:31 +00:00
refactor: enhance transaction logging for premium, stars, and TON topup methods
This commit is contained in:
@@ -118,6 +118,9 @@ async def buy_premium(username: str, months: int) -> dict:
|
||||
|
||||
logger.info("Broadcasting transaction to TON blockchain")
|
||||
tx_hash = await process_transaction(transaction)
|
||||
logger.info(
|
||||
"Premium purchase successful: %s months -> %s | tx: %s", months, username, tx_hash
|
||||
)
|
||||
return {
|
||||
"success": True,
|
||||
"data": {
|
||||
|
||||
@@ -107,6 +107,7 @@ async def buy_stars(username: str, amount: int) -> dict:
|
||||
|
||||
logger.info("Broadcasting transaction to TON blockchain")
|
||||
tx_hash = await process_transaction(transaction)
|
||||
logger.info("Stars purchase successful: %s stars -> %s | tx: %s", amount, username, tx_hash)
|
||||
return {
|
||||
"success": True,
|
||||
"data": {
|
||||
|
||||
@@ -105,6 +105,7 @@ async def topup_ton(username: str, amount: int) -> dict:
|
||||
|
||||
logger.info("Broadcasting transaction to TON blockchain")
|
||||
tx_hash = await process_transaction(transaction)
|
||||
logger.info("TON topup successful: %s TON -> %s | tx: %s", amount, username, tx_hash)
|
||||
return {
|
||||
"success": True,
|
||||
"data": {
|
||||
|
||||
Reference in New Issue
Block a user