Skip to content
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

Include Model::preventAccessingMissingAttributes in docs #10011

Closed
wants to merge 1 commit into from

Conversation

Tamas-hi
Copy link
Contributor

@Tamas-hi Tamas-hi commented Nov 2, 2024

Extend the section 'configuring-eloquent-strictness' to include more 'good practice' the developer can apply.

Extend the section 'configuring-eloquent-strictness' to include more 'good practice' the developer can apply.
@taylorotwell
Copy link
Member

I'm not really a fan of these features.

@Tamas-hi
Copy link
Contributor Author

Tamas-hi commented Nov 3, 2024

It seemed logical to add this since preventLazyLoading and preventSilentlyDiscardingAttributes are already documented.
In my context, preventAccessingMissingAttributes falls into the same category but isn’t mentioned in the docs.

image

Just wanted to note this in case it’s being reconsidered for future documentation updates.

EDIT: now I see this topic has come up a few times, and probably this is why Taylor mentioned he is not fan of the feature, caused some confusion in the past:

laravel/framework#44558
laravel/framework#44642
laravel/framework#44283

@Tamas-hi Tamas-hi changed the title Update eloquent.md Include Model::preventAccessingMissingAttributes in docs Nov 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants