File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
modules/os2forms_fbs_handler/src/Client Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -118,7 +118,7 @@ public function createPatronWithGuardian(Patron $patron, Guardian $guardian) {
118118 'pincode ' => $ patron ->pincode ,
119119 'preferredPickupBranch ' => $ patron ->preferredPickupBranch ,
120120 'name ' => 'Unknown Name ' ,
121- 'emailAddresses ' => $ patron ->emailAddresses ,
121+ 'emailAddresses ' => isset ( $ patron ->emailAddresses ) && $ patron -> emailAddresses ? $ patron -> emailAddresses : [] ,
122122 'guardian ' => $ guardian ->toArray (),
123123 'phoneNumbers ' => isset ($ patron ->phoneNumber ) && $ patron ->phoneNumber ? [
124124 [
@@ -192,7 +192,7 @@ public function updatePatron(Patron $patron): bool {
192192 $ payload = [
193193 'patron ' => [
194194 'preferredPickupBranch ' => $ patron ->preferredPickupBranch ,
195- 'emailAddresses ' => $ patron ->emailAddresses ,
195+ 'emailAddresses ' => isset ( $ patron ->emailAddresses ) && $ patron -> emailAddresses ? $ patron -> emailAddresses : [] ,
196196 'guardianVisibility ' => $ patron ->guardianVisibility ,
197197 'receivePostalMail ' => $ patron ->receiveEmail ,
198198 'phoneNumbers ' => isset ($ patron ->phoneNumber ) && $ patron ->phoneNumber ? [
You can’t perform that action at this time.
0 commit comments