Skip to content

Fix transaction ID handling in SnappPay gateway#348

Open
alissn wants to merge 1 commit into
shetabit:masterfrom
alissn:ChangeSnappPayTrnasactionId
Open

Fix transaction ID handling in SnappPay gateway#348
alissn wants to merge 1 commit into
shetabit:masterfrom
alissn:ChangeSnappPayTrnasactionId

Conversation

@alissn

@alissn alissn commented May 12, 2026

Copy link
Copy Markdown
Contributor

Hi,
This PR fixes the issue of passing the TransactionId into the SnappPay gateway.

Changes made:

  • Added a check to see if the order_id key exists in the invoice details
  • If order_id is not set, the UUID is converted to an integer using crc32() and set as the new UUID

Why this is needed:
Previously, the gateway was using getTransactionId() directly, which caused issues because the transactionId field is not populated until after the purchase() method is called.

Additional context:
This change synchronizes the SnappPay driver with the implementation used in other payment gateways, ensuring consistent behavior across the codebase.

Fixes: #338

@alissn

alissn commented Jun 14, 2026

Copy link
Copy Markdown
Contributor Author

Hi @khanzadimahdi,

Just following up on this PR. This fixes SnappPay's TransactionId handling and aligns it with the other gateways.

If you have any suggestions or concerns, please let me know and I'll be happy to make the necessary changes.

Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant