Skip to content

Commit bbb8f8a

Browse files
committed
Merge remote-tracking branch 'origin/hotfix/195-maestro-notication-recipient-santizing' into release/selvbetjening-4.6.0
2 parents 62652e1 + 6e83da3 commit bbb8f8a

2 files changed

Lines changed: 6 additions & 1 deletion

File tree

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ before starting to add changes. Use example [placed in the end of the page](#exa
1313

1414
- [PR-189](https://github.com/OS2Forms/os2forms/pull/189)
1515
- Added support for MeMo 1.2 and added additional validation of MeMo actions.
16+
- [PR-202](https://github.com/OS2Forms/os2forms/pull/202)
17+
- Removed non-digits from recipient id in Maestro digital post notifications.
1618

1719
## [4.1.0] 2025-06-03
1820

modules/os2forms_forloeb/src/MaestroHelper.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -389,7 +389,10 @@ private function sendNotificationDigitalPost(
389389
$senderLabel = $subject;
390390
$messageLabel = $subject;
391391

392-
$recipientLookupResult = $this->digitalPostHelper->lookupRecipient($recipient);
392+
// Remove all non-digits from recipient identifier.
393+
$recipientIdentifier = preg_replace('/[^\d]+/', '', $recipient);
394+
395+
$recipientLookupResult = $this->digitalPostHelper->lookupRecipient($recipientIdentifier);
393396
$actions = [
394397
(new Action())
395398
->setActionCode(SF1601::ACTION_SELVBETJENING)

0 commit comments

Comments
 (0)