Skip to content
This repository was archived by the owner on Jul 10, 2019. It is now read-only.

Commit 9b369f1

Browse files
committed
refactor: change throw from throw new Error(erro) to throw err
1 parent 5b9e0a5 commit 9b369f1

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/store/auth.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ export const actions = {
145145

146146
return data
147147
} catch (err) {
148-
throw new Error(err)
148+
throw err
149149
} finally {
150150
commit('updateBusyStatus', ['login', false])
151151
}
@@ -187,7 +187,7 @@ export const actions = {
187187

188188
return data
189189
} catch (err) {
190-
throw new Error(err)
190+
throw err
191191
} finally {
192192
commit('updateBusyStatus', ['logout', false])
193193
}
@@ -225,7 +225,7 @@ export const actions = {
225225

226226
return data
227227
} catch (err) {
228-
throw new Error(err)
228+
throw err
229229
} finally {
230230
commit('updateBusyStatus', ['loginCheck', false])
231231
}

0 commit comments

Comments
 (0)