We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 012f36d commit e3ab1ddCopy full SHA for e3ab1dd
src/stringify.js
@@ -31,8 +31,10 @@ export function stringify(value, reducers) {
31
32
/** @type {Array<{ key: string, fn: (value: any) => any }>} */
33
const custom = [];
34
- for (const key of Object.getOwnPropertyNames(reducers)) {
35
- custom.push({ key, fn: reducers[key] });
+ if (reducers) {
+ for (const key of Object.getOwnPropertyNames(reducers)) {
36
+ custom.push({ key, fn: reducers[key] });
37
+ }
38
}
39
40
/** @type {string[]} */
0 commit comments