prototype-better-error-handling #877
Annotations
4 warnings
|
PHP 8.4:
src/ErrorsWithPath.php#L97
Escaped Mutant for Mutator "UnwrapArrayMap":
@@ @@
*/
public function jsonSerialize(): array
{
- return array_map(static fn(ErrorWithPath $errorWithPath) => $errorWithPath->jsonSerialize(), $this->errorsWithPath);
+ return $this->errorsWithPath;
}
private function addErrorWithPath(ErrorWithPath $errorWithPath): self
{
|
|
PHP 8.4:
src/ErrorsWithPath.php#L24
Escaped Mutant for Mutator "UnwrapArrayMap":
@@ @@
}
public function __toString()
{
- return implode(PHP_EOL, array_map(static fn(ErrorWithPath $errorWithPath) => (string) $errorWithPath, $this->errorsWithPath));
+ return implode(PHP_EOL, $this->errorsWithPath);
}
public function addErrorsWithPath(self $errorsWithPath): self
{
|
|
PHP 8.4:
src/ErrorsWithPath.php#L24
Escaped Mutant for Mutator "CastString":
@@ @@
}
public function __toString()
{
- return implode(PHP_EOL, array_map(static fn(ErrorWithPath $errorWithPath) => (string) $errorWithPath, $this->errorsWithPath));
+ return implode(PHP_EOL, array_map(static fn(ErrorWithPath $errorWithPath) => $errorWithPath, $this->errorsWithPath));
}
public function addErrorsWithPath(self $errorsWithPath): self
{
|
|
PHP 8.4:
src/ErrorWithPath.php#L17
Escaped Mutant for Mutator "CastString":
@@ @@
}
public function __toString()
{
- return $this->path . ': ' . (string) $this->error;
+ return $this->path . ': ' . $this->error;
}
/**
* @return ErrorWithPathJson
|