Commit

cb7cf38

I’ve discovered a new Laravel feature. ❌ Post::update([‘updated_at’=>now()]); ✅ Post::touch(); I love that I’ve used it for 3 years and still find little things like this!

commit cb7cf38

I think touch() is been in Laravel for a long time now. I also like this
php
User::withoutTimestamps(function () {
    User::find(1)->update(['status' => 'active']);
});
careful with the static one though 😅 Post::touch() goes through the query builder and touches every post in the table, $post->touch() is the single one