lrf402788946 4 éve
szülő
commit
458c99da57
1 módosított fájl, 1 hozzáadás és 1 törlés
  1. 1 1
      app/service/weixin.js

+ 1 - 1
app/service/weixin.js

@@ -77,7 +77,7 @@ class WeixinAuthService extends AxiosService {
     const { appid } = this.wxInfo;
     const res = await this.httpGet('/api.weixin.qq.com/cgi-bin/user/info?lang=zh_CN', { appid, openid });
     const object = _.pick(res, [ 'nickname', 'headimgurl', 'openid' ]); // 昵称,头像,openid
-    return object;
+    return { name: object.nickname, icon: object.headimgurl, openid };
   }
   /**
    * JsApi验证