mirror of
https://github.com/barryvdh/laravel-ide-helper.git
synced 2026-08-18 18:13:11 +00:00
Test auth is binded before detect Auth driver (#946)
* Test `auth` is binded before detect Auth driver some project may not need Auth service provider * fix codingstyle
This commit is contained in:
+2
-1
@@ -123,7 +123,8 @@ class Generator
|
||||
$this->interfaces['\Illuminate\Contracts\Auth\Authenticatable'] = $defaultUserModel;
|
||||
|
||||
try {
|
||||
if (class_exists('Auth') && is_a('Auth', '\Illuminate\Support\Facades\Auth', true)) {
|
||||
if (class_exists('Auth') && is_a('Auth', '\Illuminate\Support\Facades\Auth', true)
|
||||
&& app()->bound('auth')) {
|
||||
if (class_exists('\Illuminate\Foundation\Application')) {
|
||||
$authMethod = version_compare(Application::VERSION, '5.2', '>=') ? 'guard' : 'driver';
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user