fix: allow User model instantiation with new User(['id' => $id])

We use this syntax for sending notifications without requerying the database. Also, we don't use $request->all() for anything user-related anymore so we should be safe to allow all attributes to be mass filled.
This commit is contained in:
Roardom
2025-02-26 19:18:01 +00:00
parent 51937c897e
commit b87638e1c2
+1 -1
View File
@@ -107,7 +107,7 @@ class User extends Authenticatable implements MustVerifyEmail
*
* @var string[]
*/
protected $guarded = ['id', 'created_at', 'updated_at'];
protected $guarded = [];
/**
* Get the attributes that should be cast.