From c82acafdf899cda0c8cc782d27b7f79960888748 Mon Sep 17 00:00:00 2001 From: Tokumeikoi Date: Tue, 11 Feb 2020 21:06:15 +0800 Subject: [PATCH] update api --- app/Http/Middleware/User.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Http/Middleware/User.php b/app/Http/Middleware/User.php index 15810117..9058c7d1 100755 --- a/app/Http/Middleware/User.php +++ b/app/Http/Middleware/User.php @@ -16,7 +16,7 @@ class User public function handle($request, Closure $next) { if ($request->input('access_token')) { - $user = \App\Models\User::where('token', $request->input('token'))->first(); + $user = \App\Models\User::where('token', $request->input('access_token'))->first(); if ($user) { $request->session()->put('email', $user->email); $request->session()->put('id', $user->id);