I worked on Slim 2 and recently started deploying to a production server. So far, everything is working fine. I can log in, so I know that I'm just connecting to the database. He found out who I logged in to, knowing what permissions I have as this user. I have another table with several records. When I...
$collection = collect($app->item->where('user_id', $userId)->get());
and then...
print_r($collection);
on the production server, I see the entire collection, as on the development server, but when I add ...
$pack = $collection->where('status', 1);
and instead of printing the collection, try printing the package as ...
print_r($pack);
This message is being returned ...
Illuminate\Support\Collection Object ( [items:protected] => Array ( ) )
where in the development version I get a filtered collection, as you would expect. How to change the code to work in development and production environments?
eloquent slim
user2530671
source share