button获取到的用户信息,有些信息为undefined,这是为啥?

发布于 6 年前作者 dguo1209 次浏览最后编辑 6 年前来自 ask

<button  open-type=“getUserInfo” bindgetuserinfo=“gotUserInfo”></button>

在点击button授权之后获取到的detail.userInfo里的头像地址经常为undefined,这是为啥啊,求官方解惑!!!

  • 当前 Bug 的表现(可附上截图)

这是报错的型号信息

2 回复
cuijing
cuijing1 楼6 年前

麻烦提供能复现问题的代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html

yhu
yhu2 楼4 年前

bindgetuserinfo 在调用失败的情况也会回调,你看下是否失败情况报的错