for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace App\Stream\Value;
class DataResponseProvider
{
/** @var mixed */
private $data;
private ?int $code = null;
private array $headers = [];
private ?string $format = null;
private array $params = [];
public function __construct($data, string $format = null, array $params = [])
$params
If this is a false-positive, you can also ignore this issue in your code via the ignore-unused annotation
ignore-unused
public function __construct($data, string $format = null, /** @scrutinizer ignore-unused */ array $params = [])
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.
$this->data = $data;
$this->format = $format;
}
public function getCode(): ?int
return $this->code;
public function getHeaders(): array
return $this->headers;
public function getFormat(): ?string
return $this->format;
public function getParams(): array
return $this->params;
public function getData()
return $this->data;
public function setCode(?int $code = 200): self
$this->code = $code;
return $this;
public function setHeaders(array $headers = []): self
$this->headers = $headers;
public function addHeaders(array $headers = []): self
$this->headers = [...$this->headers, ...$headers];
public function setFormat(?string $format, array $params = null): self
if ($params !== null) {
$this->params = $params;
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.