Browse Source

union ID

master
weigang 5 years ago
parent
commit
071ac9ea38
  1. 2
      app/Service/v3/Implementations/WxLoginService.php

2
app/Service/v3/Implementations/WxLoginService.php

@ -31,7 +31,7 @@ class WxLoginService implements \App\Service\v3\Interfaces\WxLoginServiceInterfa
// 更新或者插入用户数据
$user = User::query()->firstOrCreate(
['openid' => $result['openid']],
['unionid' => $result['unionid']]
['unionid' => ($result['unionid'] ?? '')]
)->toArray();
// 登录成功

Loading…
Cancel
Save