From 762324b5969db97299d1629b31b989c6c0fb7cdb Mon Sep 17 00:00:00 2001 From: Devin Binnie <52460000+devinbinnie@users.noreply.github.com> Date: Fri, 10 Nov 2023 10:48:26 -0500 Subject: [PATCH] [MM-55317] Force deep linking to use formatted path names when rewriting the URL (#2907) * [MM-55317] Force deep linking to use formatted path names when rewriting the URL * PR feedback --- src/main/views/viewManager.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/views/viewManager.ts b/src/main/views/viewManager.ts index d5396008e99..c2f27be8d6b 100644 --- a/src/main/views/viewManager.ts +++ b/src/main/views/viewManager.ts @@ -196,7 +196,8 @@ export class ViewManager { } if (browserView.isReady() && ServerManager.getRemoteInfo(browserView.view.server.id)?.serverVersion && Utils.isVersionGreaterThanOrEqualTo(ServerManager.getRemoteInfo(browserView.view.server.id)?.serverVersion ?? '', '6.0.0')) { - const pathName = `/${urlWithSchema.replace(browserView.view.server.url.toString(), '')}`; + const formattedServerURL = `${browserView.view.server.url.origin}${getFormattedPathName(browserView.view.server.url.pathname)}`; + const pathName = `/${urlWithSchema.replace(formattedServerURL, '')}`; browserView.sendToRenderer(BROWSER_HISTORY_PUSH, pathName); this.deeplinkSuccess(browserView.id); } else {