Fix default value population in ducks

This commit is contained in:
Fedor Indutny
2026-03-13 13:34:02 -07:00
committed by GitHub
parent 691eecc8b3
commit 54053d7ff6

View File

@@ -239,8 +239,9 @@ export function reducer(
if (action.type === GENERATE_FULFILLED) {
const { contact, safetyNumber } = action.payload;
const { id } = contact;
const record = state.contacts[id];
strictAssert(record, 'Missing record');
const record = state.contacts[id] || {
verificationDisabled: false,
};
return {
contacts: {
...state.contacts,