aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/login/login.component.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-04-30 15:03:09 +0200
committerChocobozzz <chocobozzz@cpy.re>2020-05-04 16:21:39 +0200
commitbc90883f1a5e9c4ecb76ae358734b85be515af7f (patch)
tree47d578c1d5a3a95e89f2badfade76b125de11084 /client/src/app/login/login.component.ts
parenta4995eb7ac5745f62604d70f7b2225ff33916d49 (diff)
downloadPeerTube-bc90883f1a5e9c4ecb76ae358734b85be515af7f.tar.gz
PeerTube-bc90883f1a5e9c4ecb76ae358734b85be515af7f.tar.zst
PeerTube-bc90883f1a5e9c4ecb76ae358734b85be515af7f.zip
Handle external login errors
Diffstat (limited to 'client/src/app/login/login.component.ts')
-rw-r--r--client/src/app/login/login.component.ts7
1 files changed, 7 insertions, 0 deletions
diff --git a/client/src/app/login/login.component.ts b/client/src/app/login/login.component.ts
index 5db8d3dbb..5d935cb49 100644
--- a/client/src/app/login/login.component.ts
+++ b/client/src/app/login/login.component.ts
@@ -23,7 +23,9 @@ export class LoginComponent extends FormReactive implements OnInit, AfterViewIni
23 23
24 error: string = null 24 error: string = null
25 forgotPasswordEmail = '' 25 forgotPasswordEmail = ''
26
26 isAuthenticatedWithExternalAuth = false 27 isAuthenticatedWithExternalAuth = false
28 externalAuthError = false
27 externalLogins: string[] = [] 29 externalLogins: string[] = []
28 30
29 private openedForgotPasswordModal: NgbModalRef 31 private openedForgotPasswordModal: NgbModalRef
@@ -61,6 +63,11 @@ export class LoginComponent extends FormReactive implements OnInit, AfterViewIni
61 return 63 return
62 } 64 }
63 65
66 if (snapshot.queryParams.externalAuthError) {
67 this.externalAuthError = true
68 return
69 }
70
64 this.buildForm({ 71 this.buildForm({
65 username: this.loginValidatorsService.LOGIN_USERNAME, 72 username: this.loginValidatorsService.LOGIN_USERNAME,
66 password: this.loginValidatorsService.LOGIN_PASSWORD 73 password: this.loginValidatorsService.LOGIN_PASSWORD