From e967c2f09b341a3766507a3eb6fda10155d04dc4 Mon Sep 17 00:00:00 2001 From: Bryan Nielsen Date: Wed, 3 Jul 2024 13:07:15 -0400 Subject: [PATCH] Fix missing model attribute errors in Laravel versions with strict mode enabled --- CHANGELOG.md | 4 ++++ src/Model.php | 2 ++ 2 files changed, 6 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 97084ed..a72a10a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,10 @@ - Control Panel access to Coilpack version information and GraphiQL for SuperAdmin Users - Dependency for updated GraphiQL [MLL\GraphiQL](https://github.com/mll-lab/laravel-graphiql) +### Fixed + +- Handling of missing model attributes when Laravel is operating in strict mode + ### Changed - Dropped support for Laravel 8 diff --git a/src/Model.php b/src/Model.php index 2603614..98deef3 100644 --- a/src/Model.php +++ b/src/Model.php @@ -8,4 +8,6 @@ class Model extends \Illuminate\Database\Eloquent\Model { protected $connection = 'coilpack'; + + protected static $modelsShouldPreventAccessingMissingAttributes = false; }