Closed cheeeasy2501 closed 4 days ago
I fixed this with cast 'translations' => AsCollection::class, but decided to report it anyway if anyone has the same problem.
Sorry, this is my file. I have overwritten the translations entry as an array. Closing the ticket ;)
Describe the bug When I fill the database via seeder and call->translateOrNew($locale) on the model, I get the error "Call to a member function firstWhere() on array"
To Reproduce
Expected behavior There is no error and everything works. I am a model as expected
Screenshots![bug-translatable](https://github.com/Astrotomic/laravel-translatable/assets/55180771/1b4f4372-22f6-44c3-aa06-328e6bf1bf17)
Versions (please complete the following information)
Additional context Add any other context about the problem here.
Exception "Call to a member function firstWhere() on array"