From b7a4762fe59ff575b9e454dc6dc2ac9173e6d5a8 Mon Sep 17 00:00:00 2001 From: Chris Manson Date: Mon, 18 Jul 2022 10:50:21 +0100 Subject: [PATCH] protect against using window apis in Fastboot --- addon/addon/components/mobile-menu/tray.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/addon/addon/components/mobile-menu/tray.js b/addon/addon/components/mobile-menu/tray.js index a28b59e1..5dc3249d 100644 --- a/addon/addon/components/mobile-menu/tray.js +++ b/addon/addon/components/mobile-menu/tray.js @@ -83,7 +83,11 @@ export default class TrayComponent extends Component { @action toggleBodyScroll(target, [isClosed]) { - if (this.args.preventScroll && !this.args.embed) { + if ( + this.args.preventScroll && + !this.args.embed && + typeof FastBoot === 'undefined' + ) { if (isClosed) { enableBodyScroll(target); } else {