Bug 42002 - SIP screen msg regexp can't be empty
Summary: SIP screen msg regexp can't be empty
Status: Signed Off
Alias: None
Product: Koha
Classification: Unclassified
Component: SIP2 (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Pedro Amorim
QA Contact: Testopia
URL:
Keywords:
Depends on: 37893
Blocks:
  Show dependency treegraph
 
Reported: 2026-03-05 15:09 UTC by Marion Durand
Modified: 2026-03-05 15:48 UTC (History)
1 user (show)

See Also:
GIT URL:
Initiative type: ---
Sponsorship status: ---
Comma delimited list of Sponsors:
Crowdfunding goal: 0
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Bug 42002: Make 'replace' in screen_msg_regex not required (1.72 KB, patch)
2026-03-05 15:27 UTC, Pedro Amorim
Details | Diff | Splinter Review
Bug 42002: Make 'replace' in screen_msg_regex not required (1.78 KB, patch)
2026-03-05 15:47 UTC, Marion Durand
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Marion Durand 2026-03-05 15:09:50 UTC
Before the migration of SIP parameters in the interface, it was possible to delete a message by replacing it with an empty string with the following code:
```
<screen_msg_regex find="Greetings from Koha. " replace="" />
```


It's no longer possible from the interface as the replace field is mandatory (a lot of our library deleted the message "Greetings from Koha. ")
Comment 1 Pedro Amorim 2026-03-05 15:27:02 UTC
Created attachment 194519 [details] [review]
Bug 42002: Make 'replace' in screen_msg_regex not required

Default to empty string if null to ensure that leaving it blank produces the required outcome: the replace value is an empty string
Comment 2 Pedro Amorim 2026-03-05 15:28:06 UTC
Hi Marion are you available to test the patch? Thank you.
Comment 3 Marion Durand 2026-03-05 15:32:02 UTC
Thank for the patch that was so quick ! I'll test right away !
Comment 4 Marion Durand 2026-03-05 15:47:47 UTC
Created attachment 194522 [details] [review]
Bug 42002: Make 'replace' in screen_msg_regex not required

Default to empty string if null to ensure that leaving it blank produces the required outcome: the replace value is an empty string

Signed-off-by: Marion Durand <marion.durand@biblibre.com>
Comment 5 Marion Durand 2026-03-05 15:48:45 UTC
All good for me ! Thanks for the lightning fast patch !