mirror of
https://github.com/status-im/react-native.git
synced 2025-01-14 03:26:07 +00:00
null gating for component tree states
Reviewed By: sebmarkbage Differential Revision: D4592611 fbshipit-source-id: ab1995e60d411c57fc59978d6d6392031334079e
This commit is contained in:
parent
f6bd8a38ec
commit
724d89d7eb
@ -61,7 +61,7 @@ function getInstanceFromTag(tag) {
|
|||||||
|
|
||||||
function getTagFromInstance(inst) {
|
function getTagFromInstance(inst) {
|
||||||
// TODO (bvaughn) Clean up once Stack is deprecated
|
// TODO (bvaughn) Clean up once Stack is deprecated
|
||||||
var tag = inst._rootNodeID || inst.stateNode._nativeTag;
|
var tag = inst._rootNodeID || (inst.stateNode && inst.stateNode._nativeTag);
|
||||||
invariant(tag, 'All native instances should have a tag.');
|
invariant(tag, 'All native instances should have a tag.');
|
||||||
return tag;
|
return tag;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user