diff --git a/src/ValueObjects/Organizer.php b/src/ValueObjects/Organizer.php index 8cfa69c..d52a6b9 100644 --- a/src/ValueObjects/Organizer.php +++ b/src/ValueObjects/Organizer.php @@ -200,7 +200,7 @@ public function getAddress(): ?TranslatedAddress return $this->address; } - public function setAddress(TranslatedAddress $address): void + public function setAddress(?TranslatedAddress $address): void { $this->address = $address; } diff --git a/src/ValueObjects/TranslatedAddress.php b/src/ValueObjects/TranslatedAddress.php index e9c477e..510187a 100644 --- a/src/ValueObjects/TranslatedAddress.php +++ b/src/ValueObjects/TranslatedAddress.php @@ -29,9 +29,7 @@ public function setAddresses(array $addresses): void public function addAddress(string $key, Address $address): void { - if (!isset($this->addresses[$key])) { - $this->addresses[$key] = $address; - } + $this->addresses[$key] = $address; } public function getAddressForLanguage(string $langcode): ?Address