Commit c64e64b4 by feixiang

parseData 优化

parent 2290bed8
......@@ -181,9 +181,9 @@ class User
}
public function initUser()
public function initUser($token)
{
if ( empty($value) ) {
if ( empty($token) ) {
return [false,AuthError::GET_TOKEN_ERROR];
}
......@@ -191,7 +191,7 @@ class User
* @var Redis $redis
*/
$redis = App::getBean(Redis::class);
$info = $redis->get('AUTH:'.$value);
$info = $redis->get('AUTH:'.$token);
if ( empty($info) ) {
return [false,AuthError::NOT_FOUND_USER];
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment