84316831 by simon

no message

1 parent 80b25105
...@@ -8,6 +8,7 @@ import router from '@/router' ...@@ -8,6 +8,7 @@ import router from '@/router'
8 import { 8 import {
9 getToken, 9 getToken,
10 setToken, 10 setToken,
11 removeToken
11 } from '@/utils/auth' 12 } from '@/utils/auth'
12 13
13 // axios的默认url 14 // axios的默认url
...@@ -49,7 +50,7 @@ axios.interceptors.response.use( ...@@ -49,7 +50,7 @@ axios.interceptors.response.use(
49 if (response.data.code === 200) { 50 if (response.data.code === 200) {
50 return Promise.resolve(response); 51 return Promise.resolve(response);
51 } else { 52 } else {
52 if (typeof (opt.toast) == "undefined" || opt.toast) { 53 if (typeof (opt) == "undefined" || typeof (opt.toast) == "undefined" || opt.toast) {
53 Toast(response.data.errMsg); 54 Toast(response.data.errMsg);
54 } 55 }
55 switch (response.data.code) { 56 switch (response.data.code) {
......