code
This commit is contained in:
@ -44,6 +44,9 @@ service.interceptors.response.use(
|
||||
* You can also judge the status by HTTP Status Code
|
||||
*/
|
||||
response => {
|
||||
if (['blob'].includes(response.config.responseType)) {
|
||||
return response.data
|
||||
}
|
||||
const code = response.data.code
|
||||
if (code === 401) {
|
||||
store.dispatch('user/resetToken')
|
||||
|
||||
Reference in New Issue
Block a user