dfws-ve-taro-request 0.0.7 → 0.0.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +3 -3
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/dist/index.umd.js +3 -3
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
package/dist/index.esm.js
CHANGED
@@ -6806,8 +6806,8 @@ var onErrorMsgRrport = function (response, options, Taro) {
|
|
6806
6806
|
};
|
6807
6807
|
var checkStatus = function (response, options, Taro) {
|
6808
6808
|
var statusCode = response.statusCode, data = response.data;
|
6809
|
-
if (statusCode >= 200 && statusCode < 300) {
|
6810
|
-
if (data.code == 400) {
|
6809
|
+
if (statusCode >= 200 && statusCode < 300 || statusCode == 406) {
|
6810
|
+
if (data.code == 400 || statusCode == 406) {
|
6811
6811
|
Taro.showToast({
|
6812
6812
|
title: data.msg,
|
6813
6813
|
icon: 'none',
|
@@ -6820,10 +6820,10 @@ var checkStatus = function (response, options, Taro) {
|
|
6820
6820
|
return data;
|
6821
6821
|
}
|
6822
6822
|
if (statusCode === 401) {
|
6823
|
-
Taro.clearStorage(); // 清除token
|
6824
6823
|
Taro.removeStorage({ key: 'ticket' });
|
6825
6824
|
Taro.removeStorage({ key: 'user_id' });
|
6826
6825
|
Taro.removeStorage({ key: 'openid' });
|
6826
|
+
Taro.removeStorage({ key: 'mobile' });
|
6827
6827
|
data.status = 0;
|
6828
6828
|
data.errMsg = "";
|
6829
6829
|
return data;
|