Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make HasTimestamps::updateTimestamps public (#33953)
I've a use-case where I construct models but can't save them yet but they should reflect the state of new models as good as it gets, including the timestamps for created/updated, which I want to do from outside the model Similar to the `touch()` method: ```php public function touch() { if (! $this->usesTimestamps()) { return false; } $this->updateTimestamps(); return $this->save(); } ``` But I don't want to save the model _yet_. I can call `usesTimestamps()` from outside the model as its already public but not yet `updateTimestamps`, thus the PR.
- Loading branch information