New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Weex Android 处理 json 对象中属性值为 null 的异常 #1133
Comments
@sospartan 看一下,stream的问题 |
@candyili 贴一下你得json数据 |
{"Res":'',"Ret":{"Time":null,"Date":20160909}} |
你先打印ret,看看是什么内容. btw: sendhttp接口将会启用,改用stream.fetch |
恩,用stream.fetch发现一个新问题: 在浏览器上调试,打印出是 “ret = [object Object] --- [object Object]”; |
fetch的数据结构与sendhttp不同,具体请看一下 http://alibaba.github.io/weex/doc/modules/stream.html, |
这个问题长时间没有讨论和反馈,如果有更多讨论仍然可以在这里继续,但这里会做close处理 |
贴代码:
retdata
为json object,其中里面有一个属性Time
的值为null
,怎么判断这个属性值是不是为null
?用了
retdata.Time == null
一直是false
(如果是用浏览器调试的话是true
,但是上了Android之后是false
),然后打印出来retdata.Time
是[object object]
The text was updated successfully, but these errors were encountered: