phpstan improvements (#3092)

This commit is contained in:
Kevin Papst
2022-01-23 15:49:38 +01:00
committed by GitHub
parent 9047e9e785
commit 9e320674c1
42 changed files with 124 additions and 118 deletions

View File

@@ -20,7 +20,7 @@ trait ColorTrait
/**
* The assigned color in HTML hex format, eg. #dd1d00
*
* @var string
* @var string|null
*
* @Serializer\Expose()
* @Serializer\Groups({"Default"})
@@ -32,9 +32,6 @@ trait ColorTrait
*/
private $color = null;
/**
* @return string
*/
public function getColor(): ?string
{
if ($this->color === Constants::DEFAULT_COLOR) {
@@ -49,9 +46,6 @@ trait ColorTrait
return null !== $this->color && $this->color !== Constants::DEFAULT_COLOR;
}
/**
* @param string $color
*/
public function setColor(?string $color = null): void
{
$this->color = $color;