diff options
author | Stas Vilchik <stas.vilchik@sonarsource.com> | 2017-10-25 15:00:26 +0200 |
---|---|---|
committer | Stas Vilchik <stas.vilchik@sonarsource.com> | 2017-10-25 17:33:29 +0200 |
commit | 4507dcbe6143a6d12d5b2a56f960b580e38245a2 (patch) | |
tree | ba5c3b2678bd996362e347305d3e163d556bebca | |
parent | c889f5e0f9bda5487b376ad13dda253dfa394605 (diff) | |
download | sonarqube-4507dcbe6143a6d12d5b2a56f960b580e38245a2.tar.gz sonarqube-4507dcbe6143a6d12d5b2a56f960b580e38245a2.zip |
show error message when fail to skip onboarding
-rw-r--r-- | server/sonar-web/src/main/js/api/users.ts | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/server/sonar-web/src/main/js/api/users.ts b/server/sonar-web/src/main/js/api/users.ts index f42c362fc74..2fb8213e139 100644 --- a/server/sonar-web/src/main/js/api/users.ts +++ b/server/sonar-web/src/main/js/api/users.ts @@ -18,6 +18,7 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ import { getJSON, post, RequestData } from '../helpers/request'; +import throwGlobalError from '../app/utils/throwGlobalError'; export interface IdentityProvider { backgroundColor: string; @@ -62,6 +63,6 @@ export function searchUsers(query: string, pageSize?: number): Promise<any> { return getJSON('/api/users/search', data); } -export function skipOnboarding(): Promise<void> { - return post('/api/users/skip_onboarding_tutorial'); +export function skipOnboarding(): Promise<void | Response> { + return post('/api/users/skip_onboarding_tutorial').catch(throwGlobalError); } |