first(); if ($user === null) { throw new BizException('用户未找到'); } return response()->json([ 'nickname' => (string) $user->userInfo->nickname, ]); } }