mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-03-11 02:12:21 -05:00
Updated settings api to ignore stripe_connect settings
refs #10318 These settings are only allowed to be set via the stripe_connect_integration_token key
This commit is contained in:
parent
53f96245e4
commit
0a257c4b5d
1 changed files with 9 additions and 2 deletions
|
@ -195,9 +195,16 @@ module.exports = {
|
|||
async query(frame) {
|
||||
const stripeConnectIntegrationToken = frame.data.settings.find(setting => setting.key === 'stripe_connect_integration_token');
|
||||
|
||||
// The `stripe_connect_integration_token` "setting" is only used to set the `stripe_connect_integration` setting.
|
||||
// The `stripe_connect_integration_token` "setting" is only used to set the `stripe_connect_*` settings.
|
||||
const settings = frame.data.settings.filter((setting) => {
|
||||
return !['stripe_connect_integration_token'].includes(setting.key);
|
||||
return ![
|
||||
'stripe_connect_integration_token',
|
||||
'stripe_connect_publishable_key',
|
||||
'stripe_connect_secret_key',
|
||||
'stripe_connect_livemode',
|
||||
'stripe_connect_account_id',
|
||||
'stripe_connect_display_name'
|
||||
].includes(setting.key);
|
||||
});
|
||||
|
||||
const getSetting = setting => settingsCache.get(setting.key, {resolve: false});
|
||||
|
|
Loading…
Add table
Reference in a new issue