From c9d6d155c397d0da0cb2d50064264fc1716f0501 Mon Sep 17 00:00:00 2001
From: Chocobozzz <florian.bigard@gmail.com>
Date: Fri, 15 Sep 2017 12:26:02 +0200
Subject: Fix login when there is an error

---
 client/src/app/shared/rest/rest-extractor.service.ts | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

(limited to 'client/src/app/shared')

diff --git a/client/src/app/shared/rest/rest-extractor.service.ts b/client/src/app/shared/rest/rest-extractor.service.ts
index 62c600d25..aafc9723e 100644
--- a/client/src/app/shared/rest/rest-extractor.service.ts
+++ b/client/src/app/shared/rest/rest-extractor.service.ts
@@ -54,11 +54,13 @@ export class RestExtractor {
 
     const errorObj = {
       message: errorMessage,
-      status: undefined
+      status: undefined,
+      body: undefined
     }
 
     if (err.status) {
       errorObj.status = err.status
+      errorObj.body = err.error
     }
 
     return Observable.throw(errorObj)
-- 
cgit v1.2.3