dfws-ve-taro-request 0.1.4 → 0.1.5

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.umd.js CHANGED
@@ -6822,7 +6822,8 @@
6822
6822
  data.status = 0;
6823
6823
  return data;
6824
6824
  }
6825
- if (typeof data.status == 'undefined' && !response.header['Content-Type'].includes('text/html')) {
6825
+ var type = response.header['Content-Type'] || response.header['content-type'] || '';
6826
+ if (typeof data.status == 'undefined' && !type.includes('text/html')) {
6826
6827
  data.status = 1;
6827
6828
  data.errMsg = "";
6828
6829
  }
@@ -6863,7 +6864,7 @@
6863
6864
  'authorization': Taro.getStorageSync('ticket'),
6864
6865
  've-version': header.version || '1.0.0',
6865
6866
  'dfws-params': header.params || '',
6866
- 'content-type': header["content-type"] || 'application/json',
6867
+ 'content-type': header["content-type"] || 'application/json;charset=utf-8',
6867
6868
  'resume-language': header['resume-language'] || 'zh-CN',
6868
6869
  'common-params': header['common-params'] || '',
6869
6870
  }