mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-24 03:14:03 +03:00
Fixed update method not using transaction for reads
no-issue Since we run our product repository methods in transactions now we must ensure that all database interations in the method use the transaction. This adds the missing options to the reading of existing prices so that they happen inside of the transaction.
This commit is contained in:
parent
b0133b3c2e
commit
3b94ba7dce
@ -311,7 +311,7 @@ class ProductRepository {
|
||||
currency: data.monthly_price.currency,
|
||||
type: 'recurring',
|
||||
interval: 'month'
|
||||
});
|
||||
}, options);
|
||||
let priceModel;
|
||||
if (existingPrice) {
|
||||
priceModel = existingPrice;
|
||||
@ -358,7 +358,7 @@ class ProductRepository {
|
||||
currency: data.yearly_price.currency,
|
||||
type: 'recurring',
|
||||
interval: 'year'
|
||||
});
|
||||
}, options);
|
||||
let priceModel;
|
||||
|
||||
if (existingPrice) {
|
||||
|
Loading…
Reference in New Issue
Block a user