Skip to content

Commit

Permalink
Merge pull request #1 from hyperh/master
Browse files Browse the repository at this point in the history
Fixed undefined navigationState.
  • Loading branch information
Mokto committed Apr 28, 2016
2 parents 44db597 + 548da4b commit dbb52db
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/meteorSwitch.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ module.exports = (getMeteorData) => {
const selected = navState.children.filter(el=>el.sceneKey==selectedKey) || console.error("key="+selectedKey+" doesn't exist");
const navigationState = selected[0] || console.error("Cannot find scene with key="+selectedKey);

if (navigationState.key != navState.children[navState.index].key){
if (!navigationState || navigationState.key != navState.children[navState.index].key){
Actions[selectedKey]();
}

Expand Down

0 comments on commit dbb52db

Please sign in to comment.