mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-20 14:43:49 +00:00
DX: apply rector rulesset up to PHP72
This commit is contained in:
@@ -527,28 +527,20 @@ class Address
|
||||
|
||||
/**
|
||||
* Set streetAddress1 (legacy function).
|
||||
*
|
||||
* @param string $streetAddress1
|
||||
*
|
||||
* @return Address
|
||||
*/
|
||||
public function setStreetAddress1($streetAddress1)
|
||||
public function setStreetAddress1(?string $streetAddress1): self
|
||||
{
|
||||
$this->street = null === $streetAddress1 ? '' : $streetAddress1;
|
||||
$this->street = (string) $streetAddress1;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set streetAddress2 (legacy function).
|
||||
*
|
||||
* @param string $streetAddress2
|
||||
*
|
||||
* @return Address
|
||||
*/
|
||||
public function setStreetAddress2($streetAddress2)
|
||||
public function setStreetAddress2(?string $streetAddress2): self
|
||||
{
|
||||
$this->streetNumber = null === $streetAddress2 ? '' : $streetAddress2;
|
||||
$this->streetNumber = (string) $streetAddress2;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
@@ -45,7 +45,7 @@ class PrivateCommentEmbeddable
|
||||
|
||||
public function merge(PrivateCommentEmbeddable $newComment): self
|
||||
{
|
||||
$currentComments = null === $this->getComments() ? [] : $this->getComments();
|
||||
$currentComments = $this->getComments() ?? [];
|
||||
|
||||
$mergedComments = $newComment->getComments() + $currentComments;
|
||||
|
||||
|
Reference in New Issue
Block a user