In a custom artisan command, I'm trying to access all of the members of a model (e.g. User) with User::all().
Records exist in the database for this model but User::all() in the command just returns "Illuminate\Database\Eloquent\Collection {#3308}" instead of the actual results.
This seems to only happen within the command as I am able to pull the results using Tinker.
Does anyone know why this would be happening?
from Newest questions tagged laravel-5 - Stack Overflow https://ift.tt/2MY8oRj
via IFTTT
Aucun commentaire:
Enregistrer un commentaire