Fix privacy settings update processing (#1903)
This commit is contained in:
parent
4cef87e2ab
commit
ac630f49c4
@ -1,6 +1,5 @@
|
|||||||
import { addActionHandler, getGlobal, setGlobal } from '../../index';
|
import { addActionHandler, getGlobal, setGlobal } from '../../index';
|
||||||
|
|
||||||
import type { ApiPrivacyKey } from '../../../types';
|
|
||||||
import { PaymentStep } from '../../../types';
|
import { PaymentStep } from '../../../types';
|
||||||
|
|
||||||
import {
|
import {
|
||||||
@ -46,7 +45,16 @@ addActionHandler('apiUpdate', (global, actions, update) => {
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case 'updatePrivacy':
|
case 'updatePrivacy':
|
||||||
global.settings.privacy[update.key as ApiPrivacyKey] = update.rules;
|
setGlobal({
|
||||||
|
...global,
|
||||||
|
settings: {
|
||||||
|
...global.settings,
|
||||||
|
privacy: {
|
||||||
|
...global.settings.privacy,
|
||||||
|
[update.key]: update.rules,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
});
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'updatePaymentVerificationNeeded':
|
case 'updatePaymentVerificationNeeded':
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user