Skip to content

Commit

Permalink
SDA-4113: Add url from CMD
Browse files Browse the repository at this point in the history
  • Loading branch information
NguyenTranHoangSym committed Mar 29, 2023
1 parent 6f9239e commit 16bba0e
Showing 1 changed file with 8 additions and 11 deletions.
19 changes: 8 additions & 11 deletions src/app/window-handler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -549,23 +549,20 @@ export class WindowHandler {
if (this.mainWebContents && !this.mainWebContents.isDestroyed()) {
// Load welcome screen
if (this.shouldShowWelcomeScreen && !this.didShowWelcomeScreen) {
const userConfigUrl =
this.userConfig.url &&
this.userConfig.url.indexOf('/login/sso/initsso') > -1
? this.userConfig.url.slice(
0,
this.userConfig.url.indexOf('/login/sso/initsso'),
)
: this.userConfig.url;
const defaultUrl = 'my.symphony.com';
const podUrl = this.userConfig.url
? this.userConfig.url
: !this.globalConfig.url.includes(defaultUrl) &&
this.globalConfig.url;
this.mainWebContents.send('page-load-welcome', {
locale: i18n.getLocale(),
resources: i18n.loadedResources,
});
this.mainWebContents.send('welcome', {
url: userConfigUrl,
url: podUrl,
message: '',
urlValid: !!userConfigUrl,
isPodConfigured: this.isPodConfigured && !!userConfigUrl,
urlValid: !!podUrl,
isPodConfigured: this.isPodConfigured && !!podUrl,
isSeamlessLoginEnabled: this.config.enableBrowserLogin,
});
this.didShowWelcomeScreen = true;
Expand Down

0 comments on commit 16bba0e

Please sign in to comment.