/** * Handle an incoming request. * * @param \Illuminate\Http\Request $request * @param \Closure $next * @return mixed */ public function handle($request, Closure $next) { if (InstallServiceProvider::isInstalled()) { abort(404); } return $next($request); }
/** * Bootstrap the application events. * * @return void */ public function boot() { if (!$this->isBootable) { return; } $this->addPublishableFiles(); // Wait until app is ready for config to be published if (!$this->isPublished()) { return; } $this->addMiddleware(); $this->providers(config('admin.providers')); $this->aliases(config('admin.aliases')); $this->commands(config('admin.commands')); Artificer::assetManager()->add(config('admin.assets', [])); $this->loadViewsFrom(__DIR__ . '/../resources/views/', 'artificer'); if (InstallServiceProvider::isExtensionDriverReady()) { Artificer::pluginManager()->boot(); Artificer::widgetManager()->boot(); } if (!$this->app->routesAreCached()) { require_once __DIR__ . '/../routes/admin.php'; } }