Skip to content

Commit d0c3d9a

Browse files
author
Jakob Tolkemit
committed
Fix phpstan
1 parent fddb1b2 commit d0c3d9a

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

src/Entity/FileContent.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ class FileContent implements ResourceInterface
1414
/** @var string */
1515
private $content;
1616

17-
public function __construct($content)
17+
public function __construct(string $content)
1818
{
19-
$this->content = (string) $content;
19+
$this->content = $content;
2020
}
2121

2222
public function getId(): int

src/Entity/OrderItemOption.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ class OrderItemOption implements OrderItemOptionInterface
6060
/** @var float */
6161
private $percent = 0;
6262

63-
/** @var FileContent */
63+
/** @var ?FileContent */
6464
private $fileContent;
6565

6666
/** {@inheritdoc} */
@@ -152,7 +152,7 @@ public function setCustomerOptionValue($value): void
152152
if ($this->customerOptionType === CustomerOptionTypeEnum::FILE) {
153153
$this->optionValue = 'file-content';
154154
$this->customerOptionValue = null;
155-
$this->fileContent = new FileContent($value);
155+
$this->fileContent = new FileContent((string) $value);
156156

157157
return;
158158
}

src/Migrations/Version20210303184909.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ final class Version20210303184909 extends AbstractMigration implements Container
2020
/** @var ?ContainerInterface */
2121
private $container;
2222

23-
public function setContainer(?ContainerInterface $container = null)
23+
public function setContainer(?ContainerInterface $container = null): void
2424
{
2525
$this->container = $container;
2626
}

0 commit comments

Comments
 (0)