Skip to content

Commit

Permalink
fix(secondaryNavigation): Fix null reference bug
Browse files Browse the repository at this point in the history
  • Loading branch information
atruskie committed Mar 21, 2016
1 parent 08015e1 commit 9759f84
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/app/navigation/secondaryNavigation.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,9 +119,11 @@ angular

function onRouteChangeStart(event, current, previous, rejection) {
renderers.forEach((renderer) => {
renderer.source.content.remove();
renderer.source.scope.$destroy();
renderer.source = null;
if (renderer.source) {
renderer.source.content.remove();
renderer.source.scope.$destroy();
renderer.source = null;
}
});

layoutCache.removeAll();
Expand Down

0 comments on commit 9759f84

Please sign in to comment.