Skip to content

Commit e67773d

Browse files
authored
fix(instruction): check if default viewport exists (#1)
1 parent cd721d4 commit e67773d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/update-footer-step.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export class UpdateFooterStep {
1616
function _findFooterModules(instruction) {
1717
let footers = [];
1818
footers.push(instruction.config.footer);
19-
let childInstruction = instruction.plan.default.childNavigationInstruction;
19+
let childInstruction = instruction.plan.default ? instruction.plan.default.childNavigationInstruction : null;
2020
while (childInstruction) {
2121
let footerModule = childInstruction.config.footer;
2222
if (footerModule) {
@@ -26,7 +26,7 @@ function _findFooterModules(instruction) {
2626
activationParam: activationParam,
2727
});
2828
}
29-
childInstruction = childInstruction.plan.default.childNavigationInstruction;
29+
childInstruction = childInstruction.plan.default ? childInstruction.plan.default.childNavigationInstruction : null;
3030
}
3131

3232
return footers;

0 commit comments

Comments
 (0)