HeyMang
HeyMang
  • 发布:2019-04-20 10:45
  • 更新:2019-07-22 15:56
  • 阅读:1016

【报Bug】(接口)发起请求 uni.request 返回结果的header的每个key结尾多出了一个空格

分类:uni-app

详细问题描述

(接口)发起请求 uni.request 返回结果的header的每个key结尾多出了一个空格

下面是我自己测试的结果:

{"data":{"code":0,"data":{"status":0},"count":null},"statusCode":200,"header":{"Transfer-Encoding ":"chunked","X-Android-Selected-Protocol ":"http/1.1","Strict-Transport-Security ":"max-age=2592000","Server ":"Kestrel","X-Android-Response-Source ":"NETWORK 200","access-token ":"+0c8dCLCrNe+hAQ17AAAtkl6Z1EqJyoVZN+WYTbrwdNiaaa4d96CdUZI+R32HGa/","X-Android-Sent-Millis ":"1555727645822","X-Android-Received-Millis ":"1555727647220","Date ":"Sat, 20 Apr 2019 02:34:07 GMT","Content-Type ":"application/json; charset=utf-8"},"errMsg":"request:ok"}

为了严谨,我给百度首页 https://www.baidu.com 也发了个请求,返回了如下结果(内容太多只截取了部分),也有个空格,所以确定是uni框架的问题

"Date ":"Sat, 20 Apr 2019 02:43:01 GMT","X-Android-Selected-Protocol ":"http/1.1","Strict-Transport-Security ":"max-age=172800","Cache-Control ":"no-cache","Tracecode ":"25815603620725775882042010 25815077320728464138042010","X-Android-Response-Source ":"NETWORK 200","Traceid ":"1555728181034914023411142736693140949391","Set-Cookie ":"BAIDUID=38A23B33AF525E07574A85D98589CE82:FG=1; max-age=31536000; expires=Sun, 19-Apr-20 02:43:01 GMT; domain=.baidu.com; path=/; version=1; comment=bd H_WISE_SIDS=127760_125704_131158_128142_129658_120144_131381_118880_118873_118840_118831_118787_131247_130765_129564_107317_129945_129750_130129_130222_131240_131194_130347_117436_130570_129648_131023_127025_130689_129008_130322_128968_131036_130609_129376_130989_129643_124030_131167_110085_121264_127969_123289_131213_130603_127417

2019-04-20 10:45 负责人:无 分享
已邀请:

最佳回复

DCloud_UNI_GSQ

DCloud_UNI_GSQ

HBuilderX 2.1 已修复此问题

  • HeyMang (作者)

    赞一个

    2019-09-23 08:26

风灯

风灯 - 有团队,接外包中。h5+,php,erlang,cocos,小程序、小游戏、付费解决uniapp,h5+问题。

同问

要回复问题请先登录注册