Skip to content

Commit 7a177dd

Browse files
authored
Fix the description of $protectFields property (#9495)
1 parent c5e1c8b commit 7a177dd

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

system/BaseModel.php

+7-3
Original file line numberDiff line numberDiff line change
@@ -121,9 +121,13 @@ abstract class BaseModel
121121
protected ?DataConverter $converter = null;
122122

123123
/**
124-
* If this model should use "softDeletes" and
125-
* simply set a date when rows are deleted, or
126-
* do hard deletes.
124+
* Determines whether the model should protect field names during
125+
* mass assignment operations such as insert() and update().
126+
*
127+
* When set to true, only the fields explicitly defined in the $allowedFields
128+
* property will be allowed for mass assignment. This helps prevent
129+
* unintended modification of database fields and improves security
130+
* by avoiding mass assignment vulnerabilities.
127131
*
128132
* @var bool
129133
*/

0 commit comments

Comments
 (0)