From e33e5ed67caa08d5ef63c553bb3fbef1aa6415a4 Mon Sep 17 00:00:00 2001 From: Arthur Lu Date: Mon, 12 Dec 2022 16:09:57 -0800 Subject: [PATCH] fix error naming --- utils.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/utils.js b/utils.js index a3eae12..2238086 100644 --- a/utils.js +++ b/utils.js @@ -33,7 +33,7 @@ export async function requestTicket (username, password) { return response; }) .catch((error) => { - if (error instanceof AuthenticationError) { + if (error instanceof ResponseError) { throw error; } throw new NetworkError(error); @@ -73,7 +73,7 @@ export async function request (path, method, body) { return response; }) .catch((error) => { - if (error instanceof AuthenticationError) { + if (error instanceof ResponseError) { throw error; } throw new NetworkError(error);