We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 197c33f commit 56a3912Copy full SHA for 56a3912
1 file changed
src/User.php
@@ -59,9 +59,9 @@ public function getClass()
59
/**
60
* 获取 具用登录信息的用户模型.
61
*
62
- * @return Model
+ * @return Model | null
63
*/
64
- public function get(): Model
+ public function get()
65
{
66
$token = $this->app->jwt->getToken();
67
@@ -77,7 +77,7 @@ public function get(): Model
77
78
$namespace = $this->getClass();
79
$model = new $namespace();
80
- $user = $model->findOrFail($uid);
+ $user = $model->find($uid);
81
82
return $user;
83
}
0 commit comments