FluxBB\Auth\AuthServiceProvider::register PHP Method

register() public method

Register the service provider.
public register ( ) : void
return void
    public function register()
    {
        $this->app->singleton('Illuminate\\Contracts\\Auth\\Guard', function () {
            $hasher = $this->app->make('Illuminate\\Contracts\\Hashing\\Hasher');
            $session = $this->app->make('Symfony\\Component\\HttpFoundation\\Session\\SessionInterface');
            $provider = new EloquentUserProvider($hasher, 'FluxBB\\Models\\User');
            $guard = new Guard($provider, $session);
            $guard->setCookieJar($this->app->make('Illuminate\\Contracts\\Cookie\\QueueingFactory'));
            $guard->setDispatcher($this->app->make('Illuminate\\Contracts\\Events\\Dispatcher'));
            $guard->setRequest($this->app->make('Symfony\\Component\\HttpFoundation\\Request'));
            return $guard;
        });
        if (Core::isInstalled()) {
            $this->app->extend('view', function ($view) {
                $view->share('user', $this->app->make('Illuminate\\Contracts\\Auth\\Guard')->user());
                return $view;
            });
        }
    }
AuthServiceProvider