mirror of
https://github.com/xtr-dev/payload-billing.git
synced 2025-12-10 02:43:24 +00:00
fix: add fallback for databases without transaction support
Some database adapters don't support transactions, causing payment updates to fail completely. This change adds graceful fallback to direct updates when transactions are unavailable. Changes: - Try to use transactions if supported - Fall back to direct update if beginTransaction() fails or returns null - Add debug logging to track which path is used - Maintain backward compatibility with transaction-supporting databases This fixes the "Failed to begin transaction" error in production. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@xtr-dev/payload-billing",
|
||||
"version": "0.1.27",
|
||||
"version": "0.1.28",
|
||||
"description": "PayloadCMS plugin for billing and payment provider integrations with tracking and local testing",
|
||||
"license": "MIT",
|
||||
"type": "module",
|
||||
|
||||
Reference in New Issue
Block a user