Add Lazy Loading prevention to app when testing
This commit is contained in:
parent
da567e0a73
commit
d41f24fdea
app/Providers
|
@ -3,6 +3,7 @@
|
||||||
namespace App\Providers;
|
namespace App\Providers;
|
||||||
|
|
||||||
use App\Form\Models\Form;
|
use App\Form\Models\Form;
|
||||||
|
use Illuminate\Database\Eloquent\Model;
|
||||||
use Illuminate\Http\RedirectResponse;
|
use Illuminate\Http\RedirectResponse;
|
||||||
use Illuminate\Http\Resources\Json\JsonResource;
|
use Illuminate\Http\Resources\Json\JsonResource;
|
||||||
use Illuminate\Support\Facades\Blade;
|
use Illuminate\Support\Facades\Blade;
|
||||||
|
@ -30,6 +31,7 @@ class AppServiceProvider extends ServiceProvider
|
||||||
app()->extend('media-library-helpers', fn ($p) => $p->put('form', Form::class));
|
app()->extend('media-library-helpers', fn ($p) => $p->put('form', Form::class));
|
||||||
|
|
||||||
Blade::componentNamespace('App\\View\\Mail', 'mail-view');
|
Blade::componentNamespace('App\\View\\Mail', 'mail-view');
|
||||||
|
Model::preventLazyLoading(!app()->isProduction());
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue