Bug 35727 - Unused code in HoldsQueue::MapItemsToHoldRequests
Summary: Unused code in HoldsQueue::MapItemsToHoldRequests
Status: Needs documenting
Alias: None
Product: Koha
Classification: Unclassified
Component: Hold requests (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Andreas Jonsson
QA Contact: Marcel de Rooy
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-01-08 16:56 UTC by Andreas Jonsson
Modified: 2024-05-24 09:43 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
24.05.00
Circulation function:


Attachments
Bug 35727 Remove unused code in HoldsQueue::MapItemsToHoldRequests (1.03 KB, patch)
2024-01-08 17:00 UTC, Andreas Jonsson
Details | Diff | Splinter Review
Bug 35727 Remove unused code in HoldsQueue::MapItemsToHoldRequests (1.08 KB, patch)
2024-01-08 21:42 UTC, David Nind
Details | Diff | Splinter Review
Bug 35727 Remove unused code in HoldsQueue::MapItemsToHoldRequests (1.18 KB, patch)
2024-04-18 12:00 UTC, Marcel de Rooy
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Andreas Jonsson 2024-01-08 16:56:37 UTC
The hash %specific_items_requested is computed but never used anywhere.  I went all the way back to v3.0.6 and couldn't find any sign that it has ever been used.


    # identify item-level requests
    my %specific_items_requested = map { $_->{itemnumber} => 1 }
                                   grep { defined($_->{itemnumber}) }
                                   @$hold_requests;
Comment 1 Andreas Jonsson 2024-01-08 17:00:58 UTC
Created attachment 160652 [details] [review]
Bug 35727 Remove unused code in HoldsQueue::MapItemsToHoldRequests

Test plan:

prove t/db_dependent/HoldsQueue.t
Comment 2 David Nind 2024-01-08 21:42:23 UTC
Created attachment 160664 [details] [review]
Bug 35727 Remove unused code in HoldsQueue::MapItemsToHoldRequests

Test plan:

prove t/db_dependent/HoldsQueue.t

Signed-off-by: David Nind <david@davidnind.com>
Comment 3 Marcel de Rooy 2024-04-18 12:00:50 UTC
Created attachment 165081 [details] [review]
Bug 35727 Remove unused code in HoldsQueue::MapItemsToHoldRequests

Test plan:

prove t/db_dependent/HoldsQueue.t

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 4 Katrin Fischer 2024-04-29 07:38:20 UTC
Pushed for 24.05!

Well done everyone, thank you!
Comment 5 Fridolin Somers 2024-05-24 09:43:24 UTC
Not backported to 23.11.x