📅  最后修改于: 2022-03-11 14:53:54.252000             🧑  作者: Mango
public function logout() {
Auth::user()->tokens->each(function($token, $key) {
$token->delete();
});
return response()->json('Successfully logged out');
}