Skip to content

[9.x] Add replicateQuietly to Model#43141

Merged
taylorotwell merged 2 commits intolaravel:9.xfrom
Sergiobop:9.x
Jul 12, 2022
Merged

[9.x] Add replicateQuietly to Model#43141
taylorotwell merged 2 commits intolaravel:9.xfrom
Sergiobop:9.x

Conversation

@Sergiobop
Copy link
Copy Markdown
Contributor

Description

This PR adds a method to easily replicate a model without raising any events. This method is similar to the existing saveQuietly, incrementQuietly, decrementQuietly...
Also added a test.

Usage

$replicated = $model->replicateQuietly();

Should not break any existing features.
Thanks for your time!

@taylorotwell taylorotwell merged commit 14893ea into laravel:9.x Jul 12, 2022
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