0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-03-25 02:31:59 -05:00

Errored when creating products if any error occurs

refs https://github.com/TryGhost/Team/issues/982

When creating a Product with invalid data for Stripe, e.g. a price of
one gazillion dollars - the Stripe API requests would fail, but we would
end up with a broken product created in the database. This updates
@tryghost/members-api to wrap these calls in a database transaction, and
will roll back any operations if one of them fails.
This commit is contained in:
Fabien O'Carroll 2021-08-26 20:10:31 +02:00
parent bee1d4793d
commit b895b87add
2 changed files with 5 additions and 5 deletions

View file

@ -73,7 +73,7 @@
"@tryghost/limit-service": "0.6.1",
"@tryghost/logging": "0.1.5",
"@tryghost/magic-link": "1.0.10",
"@tryghost/members-api": "1.28.0",
"@tryghost/members-api": "1.29.0",
"@tryghost/members-csv": "1.1.5",
"@tryghost/members-importer": "0.3.1",
"@tryghost/members-ssr": "1.0.11",

View file

@ -908,10 +908,10 @@
jsonwebtoken "^8.5.1"
lodash "^4.17.15"
"@tryghost/members-api@1.28.0":
version "1.28.0"
resolved "https://registry.yarnpkg.com/@tryghost/members-api/-/members-api-1.28.0.tgz#97b4ebf826f0b6f34cd6eb4affe8ee77c369a2b6"
integrity sha512-1uEp3D47B+4574UPEhrquyXry6rMN6odl8N8uciu6zXvDDK6SDqnS68EevrerDJyT0nKd8cq4r+JBpr+kcUCfg==
"@tryghost/members-api@1.29.0":
version "1.29.0"
resolved "https://registry.yarnpkg.com/@tryghost/members-api/-/members-api-1.29.0.tgz#147b510b990b19473e170a914983439f2b883695"
integrity sha512-a1R7BO/Q4ZQOyNJ67rJBq9vb3xk5BQYcM6z7XqsryWUnszxSIV2PjKMEcecJNMZiMGBUqURlMq5d3kPkqzloiw==
dependencies:
"@tryghost/debug" "^0.1.2"
"@tryghost/errors" "^0.2.9"