From c8d3772635aa5d05662106ea64741d8abe38f4d8 Mon Sep 17 00:00:00 2001 From: Jacob Overgaard <752371+iOvergaard@users.noreply.github.com> Date: Fri, 24 May 2024 10:57:24 +0200 Subject: [PATCH] fix: make sure the opener came from within the backoffice itself --- src/Umbraco.Web.UI.Client/src/apps/app/app.element.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/src/apps/app/app.element.ts b/src/Umbraco.Web.UI.Client/src/apps/app/app.element.ts index b614d5acd4..3e4b82e0cf 100644 --- a/src/Umbraco.Web.UI.Client/src/apps/app/app.element.ts +++ b/src/Umbraco.Web.UI.Client/src/apps/app/app.element.ts @@ -79,8 +79,9 @@ export class UmbAppElement extends UmbLitElement { // If we are in the main window, the signal will be caught right here and the user will be redirected to the root. if ( window.opener && - window.opener instanceof Window && - window.opener.location.origin === window.location.origin + window.opener !== window && + window.opener.location.origin === window.location.origin && + window.opener.location.pathname.startsWith(this.backofficePath) ) { (component as UmbAppErrorElement).errorMessage = hasCode ? this.localize.term('errors_externalLoginSuccess')