aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/login
diff options
context:
space:
mode:
authorChocobozzz <florian.bigard@gmail.com>2016-08-23 16:54:21 +0200
committerChocobozzz <florian.bigard@gmail.com>2016-08-23 16:54:21 +0200
commitde59c48f5f317018e3f746bbe4a7b7efe00109f2 (patch)
treebc3d007c5aaed8dc72119763f3b1731c5777f218 /client/src/app/login
parentdef16d33d19153c6583fa8a30634760b3d64d34c (diff)
downloadPeerTube-de59c48f5f317018e3f746bbe4a7b7efe00109f2.tar.gz
PeerTube-de59c48f5f317018e3f746bbe4a7b7efe00109f2.tar.zst
PeerTube-de59c48f5f317018e3f746bbe4a7b7efe00109f2.zip
Client: centralize http res extraction in a service
Diffstat (limited to 'client/src/app/login')
-rw-r--r--client/src/app/login/login.component.ts6
1 files changed, 3 insertions, 3 deletions
diff --git a/client/src/app/login/login.component.ts b/client/src/app/login/login.component.ts
index fe867b7b4..1e0ba0fe8 100644
--- a/client/src/app/login/login.component.ts
+++ b/client/src/app/login/login.component.ts
@@ -37,12 +37,12 @@ export class LoginComponent implements OnInit {
37 this.router.navigate(['/videos/list']); 37 this.router.navigate(['/videos/list']);
38 }, 38 },
39 error => { 39 error => {
40 console.error(error); 40 console.error(error.json);
41 41
42 if (error.error === 'invalid_grant') { 42 if (error.json.error === 'invalid_grant') {
43 this.error = 'Credentials are invalid.'; 43 this.error = 'Credentials are invalid.';
44 } else { 44 } else {
45 this.error = `${error.error}: ${error.error_description}`; 45 this.error = `${error.json.error}: ${error.json.error_description}`;
46 } 46 }
47 } 47 }
48 ); 48 );