done with task: check if transaction exists in the database #12
@@ -17,7 +17,7 @@ class SimbrellaClient:
|
|||||||
|
|
||||||
# Check if the transaction exists
|
# Check if the transaction exists
|
||||||
logger.info(f"Checking if transaction exists")
|
logger.info(f"Checking if transaction exists")
|
||||||
transaction = TransactionService.get_transaction_by_id(transaction_id=data['transactionId'])
|
transaction = TransactionService.get_transaction_by_transaction_id(transaction_id=data['transactionId'])
|
||||||
logger.info(f"Response from database: {transaction}")
|
logger.info(f"Response from database: {transaction}")
|
||||||
|
|
||||||
if not transaction:
|
if not transaction:
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ from app.models import Transaction
|
|||||||
class TransactionService:
|
class TransactionService:
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def get_transaction_by_id(transaction_id):
|
def get_transaction_by_transaction_id(transaction_id):
|
||||||
"""
|
"""
|
||||||
Get the transaction by ID
|
Get the transaction by ID
|
||||||
"""
|
"""
|
||||||
|
|||||||
Reference in New Issue
Block a user