diff --git a/src/Platform/Providers/FoundationServiceProvider.php b/src/Platform/Providers/FoundationServiceProvider.php index 5f9e65767..1a429e7a4 100644 --- a/src/Platform/Providers/FoundationServiceProvider.php +++ b/src/Platform/Providers/FoundationServiceProvider.php @@ -97,7 +97,11 @@ public function registerOctaneEventsListen(): self */ public function registerLoginEventsListen():self { - Event::listen(Login::class, LockUserForLogin::class,); + if (config('platform.auth', true)) { + Event::listen(Login::class, LockUserForLogin::class); + } + + return $this; } /**