Skip to content

Commit 77be23b

Browse files
refactor message
Signed-off-by: nkomonen-amazon <[email protected]>
1 parent 112c333 commit 77be23b

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

packages/core/src/auth/sso/constants.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,4 @@ export const ssoUrlFormatRegex =
2222
* below, so this message is only a warning.
2323
*/
2424
export const ssoUrlFormatMessage = 'URL possibly invalid. Expected format: https://xxxxxxxxxx.awsapps.com/start'
25+
export const urlInvalidFormatMessage = 'URL format invalid. Expected format: https://xxxxxxxxxx.com/yyyy'

packages/core/src/login/webview/vue/login.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -279,7 +279,7 @@ import { LoginOption } from './types'
279279
import { CommonAuthWebview } from './backend'
280280
import { WebviewClientFactory } from '../../../webviews/client'
281281
import { Region } from '../../../shared/regions/endpoints'
282-
import { ssoUrlFormatRegex, ssoUrlFormatMessage } from '../../../auth/sso/constants'
282+
import { ssoUrlFormatRegex, ssoUrlFormatMessage, urlInvalidFormatMessage } from '../../../auth/sso/constants'
283283
284284
const client = WebviewClientFactory.create<CommonAuthWebview>()
285285
@@ -504,7 +504,7 @@ export default defineComponent({
504504
console.log('After Validate')
505505
return { error: '', warning: ssoUrlFormatMessage }
506506
} else {
507-
return { error: 'URL format invalid. Must follow eg: https://xxxxx.com/yyyy', warning: '' }
507+
return { error: urlInvalidFormatMessage, warning: '' }
508508
}
509509
}
510510

0 commit comments

Comments
 (0)