for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace LivePersonInc\LiveEngageLaravel\Collections;
use Illuminate\Support\Collection;
use LivePersonInc\LiveEngageLaravel\Models\Agent;
class AgentParticipants extends Collection
{
public function __construct(array $models = [])
$models = array_map(function($item) {
return new Agent((array) $item);
}, $models);
parent::__construct($models);
}
public function state($state = 'ONLINE')
$result = $this->filter(function($value, $key) use ($state) {
$key
If this is a false-positive, you can also ignore this issue in your code via the ignore-unused annotation
ignore-unused
$result = $this->filter(function($value, /** @scrutinizer ignore-unused */ $key) use ($state) {
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.
return strtolower($value->currentStatus) == strtolower($state);
});
return $result;
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.