Skip to content

Commit 14600a7

Browse files
committed
Changing Auth facade to app['auth']
Since Lumen defaults to no facades
1 parent 396da16 commit 14600a7

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

app/Providers/AuthServiceProvider.php

+1-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
namespace App\Providers;
44

55
use App\User;
6-
use Illuminate\Support\Facades\Auth;
76
use Illuminate\Support\Facades\Gate;
87
use Illuminate\Support\ServiceProvider;
98

@@ -31,7 +30,7 @@ public function boot()
3130
// should return either a User instance or null. You're free to obtain
3231
// the User instance via an API token or any other method necessary.
3332

34-
Auth::viaRequest('api', function ($request) {
33+
$this->app['auth']->viaRequest('api', function ($request) {
3534
if ($request->input('api_token')) {
3635
return User::where('api_token', $request->input('api_token'))->first();
3736
}

0 commit comments

Comments
 (0)