diff --git a/src/Bundle/ChillPersonBundle/Entity/Person.php b/src/Bundle/ChillPersonBundle/Entity/Person.php index 59570f956..4680581cd 100644 --- a/src/Bundle/ChillPersonBundle/Entity/Person.php +++ b/src/Bundle/ChillPersonBundle/Entity/Person.php @@ -284,7 +284,7 @@ class Person implements HasCenterInterface, TrackCreationInterface, TrackUpdateI * max=255, * ) */ - private $firstName; + private string $firstName = ''; /** * fullname canonical. Read-only field, which is calculated by @@ -294,7 +294,7 @@ class Person implements HasCenterInterface, TrackCreationInterface, TrackUpdateI * * @ORM\Column(type="text", nullable=true) */ - private $fullnameCanonical; + private string $fullnameCanonical = ''; /** * The person's gender. @@ -353,7 +353,7 @@ class Person implements HasCenterInterface, TrackCreationInterface, TrackUpdateI * max=255, * ) */ - private $lastName; + private string $lastName = ''; /** * The marital status of the person. @@ -1583,9 +1583,9 @@ class Person implements HasCenterInterface, TrackCreationInterface, TrackUpdateI return $this; } - public function setFirstName(string $firstName): self + public function setFirstName(?string $firstName): self { - $this->firstName = $firstName; + $this->firstName = (string) $firstName; return $this; } @@ -1611,9 +1611,9 @@ class Person implements HasCenterInterface, TrackCreationInterface, TrackUpdateI return $this; } - public function setLastName(string $lastName): self + public function setLastName(?string $lastName): self { - $this->lastName = $lastName; + $this->lastName = (string) $lastName; return $this; }