<?php namespace Analogue\LaravelAuth;

use Illuminate\Support\ServiceProvider;
use Illuminate\Auth\AuthManager;

class AnalogueAuthServiceProvider extends ServiceProvider {

	/**
	 * Indicates if loading of the provider is deferred.
	 *
	 * @var bool
	 */
	protected $defer = true;

	public function boot()
	{
		//	
	}

	/**
	 * Register the service provider.
	 *
	 * @return void
	 */
	public function register()
	{
		$this->app[AuthManager::class]->provider('analogue', function($app, $config) {
			return new AnalogueUserProvider(
				$app['Illuminate\Contracts\Hashing\Hasher'],
				$app['analogue'],
				$config['model']
			);
		});
	}

	/**
	 * Get the services provided by the provider.
	 *
	 * @return array
	 */
	public function provides()
	{
		return array();
	}

}

<?php namespace Analogue\LaravelAuth;

use Illuminate\Support\ServiceProvider;
use Illuminate\Auth\AuthManager;

class AnalogueAuthServiceProvider extends ServiceProvider {

	/**
	 * Indicates if loading of the provider is deferred.
	 *
	 * @var bool
	 */
	protected $defer = false;

	public function boot()
	{
		$this->app[AuthManager::class]->extend('analogue', function ($app) {
			
			return new AnalogueUserProvider(
				$app['Illuminate\Contracts\Hashing\Hasher'],
				$app['analogue'],
				$app['config']['auth.model']
			);
		});
	}

	/**
	 * Register the service provider.
	 *
	 * @return void
	 */
	public function register()
	{
		//
	}

	/**
	 * Get the services provided by the provider.
	 *
	 * @return array
	 */
	public function provides()
	{
		return array();
	}

}

--- 
+++ 
@@ -10,18 +10,11 @@
 	 *
 	 * @var bool
 	 */
-	protected $defer = false;
+	protected $defer = true;
 
 	public function boot()
 	{
-		$this->app[AuthManager::class]->extend('analogue', function ($app) {
-			
-			return new AnalogueUserProvider(
-				$app['Illuminate\Contracts\Hashing\Hasher'],
-				$app['analogue'],
-				$app['config']['auth.model']
-			);
-		});
+		//	
 	}
 
 	/**
@@ -31,7 +24,13 @@
 	 */
 	public function register()
 	{
-		//
+		$this->app[AuthManager::class]->provider('analogue', function($app, $config) {
+			return new AnalogueUserProvider(
+				$app['Illuminate\Contracts\Hashing\Hasher'],
+				$app['analogue'],
+				$config['model']
+			);
+		});
 	}
 
 	/**
Use provider() instead of extends()
