firstOrNew should use $values
param to fill when existing record found
#33798
Unanswered
patrick-radius
asked this question in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Last week i kinda created a situation in our system because i (wrongly) assumed that the
firstOrNew
method was behaving the same as theupdateOrCreate
method minus the writing to the database.But after looking at the framework code we found out that firstOrNew does nothing with the
$values
parameter when it finds an existing model.Why not do a fill on the existing model after it found it?
Beta Was this translation helpful? Give feedback.
All reactions