Skip to content

Commit 17ad5e7

Browse files
JackBuchananjack7anderson7
authored andcommitted
Fix #10513 - When field to be updated is email1 then use new logic to update related email account record
Load relationship and set email_address and email_address_caps
1 parent 1a114a9 commit 17ad5e7

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

Api/V8/Service/ModuleService.php

+8
Original file line numberDiff line numberDiff line change
@@ -473,6 +473,14 @@ protected function processAttributes(&$bean, $attributes)
473473
} elseif ($property === 'filename') {
474474
$createFile = true;
475475
continue;
476+
477+
} elseif ($property === 'email1') {
478+
foreach ($bean->emailAddress->addresses as $index => $email) {
479+
if ($email['email_address'] === $bean->$property) {
480+
$bean->emailAddress->addresses[$index]['email_address'] = $value;
481+
$bean->emailAddress->addresses[$index]['email_address_caps'] = strtoupper($value);
482+
}
483+
}
476484
}
477485

478486
$bean->$property = $value;

0 commit comments

Comments
 (0)