From 7622bfd45ce83453868ab624865b3d661db8cb7e Mon Sep 17 00:00:00 2001 From: Julien Veyssier Date: Thu, 19 Sep 2024 13:18:39 +0200 Subject: [PATCH] fix: if address attr is an object but can't be parsed to an array, give null to the 'attr mapped' event Signed-off-by: Julien Veyssier --- lib/Service/ProvisioningService.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/Service/ProvisioningService.php b/lib/Service/ProvisioningService.php index 524ebf15..cf73551d 100644 --- a/lib/Service/ProvisioningService.php +++ b/lib/Service/ProvisioningService.php @@ -193,6 +193,8 @@ public function provisionUser(string $tokenUserId, int $providerId, object $idTo $addressArray[$regionAttribute] ?? '', $addressArray[$countryAttribute] ?? '', ]; + } else { + $address = null; } } elseif ($street !== null || $postalcode !== null || $locality !== null || $region !== null || $country !== null) { // Concatenate the address components