Bug 29321

Summary: Remove a last without loop context
Product: Koha Reporter: Marcel de Rooy <m.de.rooy>
Component: Architecture, internals, and plumbingAssignee: Marcel de Rooy <m.de.rooy>
Status: CLOSED FIXED QA Contact: Tomás Cohen Arazi <tomascohen>
Severity: minor    
Priority: P5 - low CC: fridolin.somers, jonathan.druart, kyle, tomascohen, victor
Version: Main   
Hardware: All   
OS: All   
See Also: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29416
Change sponsored?: --- Patch complexity: Trivial patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
21.11.00,21.05.05,20.11.12
Bug Depends on: 23420    
Bug Blocks:    
Attachments: Bug 29321: Reduce log size by dumping and truncating
Bug 29321: Remove a last without loop context
Bug 29321: Remove a last without loop context

Description Marcel de Rooy 2021-10-26 12:18:07 UTC

    
Comment 1 Marcel de Rooy 2021-10-26 12:18:27 UTC Comment hidden (obsolete)
Comment 2 Marcel de Rooy 2021-10-26 14:54:22 UTC Comment hidden (obsolete)
Comment 3 Marcel de Rooy 2021-11-05 15:06:41 UTC
Created attachment 127396 [details] [review]
Bug 29321: Remove a last without loop context

This reads better when converted to regular if.
Note that last within such a block is allowed in Perl, but it feels
better to use it only in a loop context.

Test plan:
Read the patch ;)
Bonus: Test if you enter the block by using pref OPACSuggestionMandatoryFields
when adding a suggestion from opac.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 4 Marcel de Rooy 2021-11-05 15:09:46 UTC
Self signoff
Comment 5 Tomás Cohen Arazi 2021-11-11 20:50:53 UTC
Created attachment 127555 [details] [review]
Bug 29321: Remove a last without loop context

This reads better when converted to regular if.
Note that last within such a block is allowed in Perl, but it feels
better to use it only in a loop context.

Test plan:
Read the patch ;)
Bonus: Test if you enter the block by using pref OPACSuggestionMandatoryFields
when adding a suggestion from opac.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Edit: Added a space between 'if' and '(' :-D
Comment 6 Jonathan Druart 2021-11-15 11:40:06 UTC
Pushed to master for 21.11, thanks to everybody involved!
Comment 7 Kyle M Hall 2021-11-19 16:35:53 UTC
Pushed to 21.05.x for 21.05.05
Comment 8 Fridolin Somers 2021-11-20 00:14:32 UTC
Pushed to 20.11.x for 20.11.12
Comment 9 Victor Grousset/tuxayo 2021-11-22 01:41:42 UTC
Not backported to oldoldstable (20.05.x). Feel free to ask if it's needed.