Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SDA-4113: Add url from CMD #1810

Merged
merged 1 commit into from
Mar 30, 2023

Conversation

NguyenTranHoangSym
Copy link
Contributor

Description

POD_URL will now be able to update URL at welcome screen

Related PRs

@NguyenTranHoangSym NguyenTranHoangSym self-assigned this Mar 28, 2023
@NguyenTranHoangSym NguyenTranHoangSym marked this pull request as ready for review March 28, 2023 07:54
const defaultUrl = 'my.symphony.com';
const podUrl = !this.globalConfig.url.includes(defaultUrl)
? this.globalConfig.url
: this.userConfig.url;
const userConfigUrl =
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it can be removed

const defaultUrl = 'my.symphony.com';
const podUrl = !this.globalConfig.url.includes(defaultUrl)
? this.globalConfig.url
: this.userConfig.url;
const userConfigUrl =
this.userConfig.url &&
this.userConfig.url.indexOf('/login/sso/initsso') > -1
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same logic should be on podUrl

@@ -549,23 +549,28 @@ export class WindowHandler {
if (this.mainWebContents && !this.mainWebContents.isDestroyed()) {
// Load welcome screen
if (this.shouldShowWelcomeScreen && !this.didShowWelcomeScreen) {
const userConfigUrl =
const defaultUrl = 'my.symphony.com';
const customUrl = this.userConfig.url.slice(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe you need to be safer here, url can be not set if it's a first time launch --> slice of undefined --> error
Also, you could rename it customUserConfigUrl

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

here I think there is no need to do the check on sso, let's do it once and forall on podUrl, wdyt?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sbenmoussati
Hmm I dont seem to get the idea here. customUserConfigUrl meant to get the config instead.
at PodUrl:
Check if userconfig contains sso
get the value and assign to customUserConfigUrl

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants