Skip to content

docs: Fix the description of $protectFields property #9495

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 21, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions system/BaseModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -121,9 +121,13 @@ abstract class BaseModel
protected ?DataConverter $converter = null;

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