FEATURE #2503: add easier installer
This commit is contained in:
@@ -6,6 +6,7 @@ use App\CMS\Contracts\Repositories\Template as TemplateContract;
|
||||
use App\CMS\Handlers\Registrators\TemplateRegistrator;
|
||||
use App\CMS\Helpers\CurrentTemplate;
|
||||
use App\CMS\Repositories\Module;
|
||||
use Illuminate\Database\QueryException;
|
||||
use Illuminate\Support\Facades\App;
|
||||
use Illuminate\Support\ServiceProvider;
|
||||
|
||||
@@ -13,7 +14,11 @@ class TemplateServiceProvider extends ServiceProvider
|
||||
{
|
||||
public function boot()
|
||||
{
|
||||
$template = CurrentTemplate::get();
|
||||
try {
|
||||
$template = CurrentTemplate::get();
|
||||
} catch (QueryException $e) {
|
||||
return;
|
||||
}
|
||||
|
||||
// ignore running from artisan
|
||||
if (App::runningInConsole() || App::environment('testing') || !$template) {
|
||||
|
||||
Reference in New Issue
Block a user