From b866344310379d85ccd5630781207b73aada092a Mon Sep 17 00:00:00 2001 From: FangyuanCheng Date: Wed, 5 Dec 2018 09:47:43 +0800 Subject: [PATCH] Modify the error message when adding members Signed-off-by: FangyuanCheng --- src/portal/src/app/shared/shared.utils.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/portal/src/app/shared/shared.utils.ts b/src/portal/src/app/shared/shared.utils.ts index 8f3700123..8c087dbfb 100644 --- a/src/portal/src/app/shared/shared.utils.ts +++ b/src/portal/src/app/shared/shared.utils.ts @@ -26,6 +26,9 @@ import { httpStatusCode, AlertType } from './shared.const'; * returns {string} */ export const errorHandler = function (error: any): string { + if (typeof error === "string") { + return error; + } if (error && error._body) { // treat as string message if (typeof error._body === "string") {