[database] fix flow issue
This commit is contained in:
parent
c275e02fcc
commit
5589ed7f4f
@ -62,7 +62,9 @@ export default class DataSnapshot {
|
|||||||
// todo this is wrong - child keys needs to be the ordered keys, from FB
|
// todo this is wrong - child keys needs to be the ordered keys, from FB
|
||||||
// todo potential solution is build up a tree/map of a snapshot and its children
|
// todo potential solution is build up a tree/map of a snapshot and its children
|
||||||
// todo natively and send that back to JS to be use in this class.
|
// todo natively and send that back to JS to be use in this class.
|
||||||
childKeys: isObject(value) ? Object.keys(value) : [],
|
|
||||||
|
// null check to keep flow happy even though isObject already does this
|
||||||
|
childKeys: isObject(value) && value !== null ? Object.keys(value) : [],
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user