collection eloquent laravel empty code example Example: collection empty laravel $isempty = $collection->isEmpty();