Skip to content

Commit 78b34c2

Browse files
committed
fix(getmarbletokenvalue): Check for undefined values for given token
Test explicitly for undefined values so that values like { a : false | null | 0 } get passed through properly None
1 parent b4563ac commit 78b34c2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/marbles/tokenParseReducer.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ const getMarbleTokenValue = <T>(
5858
value: { [key: string]: T } | null,
5959
materializeInnerObservables: boolean
6060
) => {
61-
const customValue = value && value[token] ? value[token] : token;
61+
const customValue = value && typeof value[token] !== 'undefined' ? value[token] : token;
6262

6363
return materializeInnerObservables && customValue instanceof ColdObservable ? customValue.messages : customValue;
6464
};

0 commit comments

Comments
 (0)