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

[9.x] Make HasTimestamps::updateTimestamps chainable #42533

Merged
merged 2 commits into from
May 26, 2022

Conversation

leandro-hermes
Copy link
Contributor

@leandro-hermes leandro-hermes commented May 26, 2022

This PR makes the method HasTimestamps::updateTimestamps chainable, so we can do:

$model->updateTimestamps()->save();

@taylorotwell taylorotwell merged commit 6999399 into laravel:9.x May 26, 2022
@taylorotwell
Copy link
Member

Don't mind merging this, but for your example you can just do $model->touch()

@leandro-hermes leandro-hermes deleted the leandro-hermes-patch-1 branch May 26, 2022 17:46
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