From 56c9030d35f8104c2973c1bf3911274cb5b164fa Mon Sep 17 00:00:00 2001 From: iamareebjamal Date: Mon, 10 Feb 2020 00:22:18 +0530 Subject: [PATCH 1/2] fix: Disable role invite processing in fastboot mode --- app/routes/public/role-invites.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/app/routes/public/role-invites.js b/app/routes/public/role-invites.js index 9f6539bb82b..f264e0a9a09 100644 --- a/app/routes/public/role-invites.js +++ b/app/routes/public/role-invites.js @@ -1,8 +1,14 @@ import Route from '@ember/routing/route'; +import { inject as service } from '@ember/service'; export default Route.extend({ + fastboot: service(), redirectionParams: null, async beforeModel(transition) { + // We don't want to process or transition in fastboot mode + // Since this is only an intermediate page + if (this.fastboot.isFastBoot) + return; const { token } = transition.to.queryParams; const originalEventId = transition.resolvedModels.public.originalId; const payload = { @@ -31,6 +37,8 @@ export default Route.extend({ }, afterModel() { + if (this.fastboot.isFastBoot) + return; this.transitionTo('register', this.redirectionParams); } }); From bb398712dbd9586891a9666b1776598c1b741328 Mon Sep 17 00:00:00 2001 From: iamareebjamal Date: Mon, 10 Feb 2020 00:57:06 +0530 Subject: [PATCH 2/2] fix --- app/routes/public/role-invites.js | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/app/routes/public/role-invites.js b/app/routes/public/role-invites.js index f264e0a9a09..b264399e23f 100644 --- a/app/routes/public/role-invites.js +++ b/app/routes/public/role-invites.js @@ -2,13 +2,12 @@ import Route from '@ember/routing/route'; import { inject as service } from '@ember/service'; export default Route.extend({ - fastboot: service(), - redirectionParams: null, + fastboot : service(), + redirectionParams : null, async beforeModel(transition) { // We don't want to process or transition in fastboot mode // Since this is only an intermediate page - if (this.fastboot.isFastBoot) - return; + if (this.fastboot.isFastBoot) {return} const { token } = transition.to.queryParams; const originalEventId = transition.resolvedModels.public.originalId; const payload = { @@ -37,8 +36,7 @@ export default Route.extend({ }, afterModel() { - if (this.fastboot.isFastBoot) - return; + if (this.fastboot.isFastBoot) {return} this.transitionTo('register', this.redirectionParams); } });