You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Where you able to trace back in which of your tables this error happened? If so, would you mind sharing its structure with me? Does it have a primary key? No problem if you can't. Thanks in advance 👍
I tracked it to a table that didn't have a primary key
I confirmed by adding a primary key of id and I removed the aforementioned fix and no errors occurred
When I removed that primary key, then the error happened again.
I hope this helps
Laravel 5.3
I am getting an Invalid Argument supplied for foreach error when using php artisan code:models
I traced it back to Models line 1036
I fixed it by checking if primaryKeys->columns is an array before processing the foreach block
Updated code is below
Please confirm and add this possible fix if you want.
The text was updated successfully, but these errors were encountered: