|
@@ -54,9 +54,8 @@ class MiniProgram extends Api
|
|
|
//解密获取用户信息
|
|
|
$userInfo = MiniProgramService::encryptor($this->cid,$session_key, $data['iv'], $data['encryptedData']);
|
|
|
} catch (\Exception $e) {
|
|
|
- $this->error('签名无效,重新刷新');
|
|
|
+ $this->error('签名无效,重新刷新'.$e->getMessage());
|
|
|
}
|
|
|
- @file_put_contents("user.txt",json_encode($userInfo).'--'.json_encode($userInfoCong));
|
|
|
if (!isset($userInfo['unionId'])) $userInfo['unionId'] = '';
|
|
|
if(!$userInfo['openId']) $userInfo['openId'] = $userInfoCong['openid'];
|
|
|
if(!$userInfo['openId']) $this->error('获取openId失败!');
|