diff --git a/app/Service/Api/Login/LoginBaseService.php b/app/Service/Api/Login/LoginBaseService.php index 5447554..f5dcdf5 100644 --- a/app/Service/Api/Login/LoginBaseService.php +++ b/app/Service/Api/Login/LoginBaseService.php @@ -279,7 +279,7 @@ abstract class LoginBaseService extends BaseService if ($this->userModel->checkInviteCodeIsUse($inviteCode) == 1) return; - if (!$this->userModel->where('id', $inviteCode)->update(['invite_code' => $inviteCode])) throw new ErrException('注册失败-00004'); + if (!$this->userModel->where('id', $this->userId)->update(['invite_code' => $inviteCode])) throw new ErrException('注册失败-00004'); } /**