Bug 10256 - Remove some unused subs from Overdues module
Summary: Remove some unused subs from Overdues module
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Circulation (show other bugs)
Version: Main
Hardware: All All
: P5 - low minor (vote)
Assignee: Marcel de Rooy
QA Contact: Jonathan Druart
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-05-16 07:53 UTC by Marcel de Rooy
Modified: 2014-12-07 20:02 UTC (History)
4 users (show)

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


Attachments
Bug 10256: Remove some unused subs from Overdues module (13.88 KB, patch)
2013-05-16 08:07 UTC, Marcel de Rooy
Details | Diff | Splinter Review
Bug 10256: Remove some unused subs from Overdues module (13.89 KB, patch)
2013-06-07 16:17 UTC, Kyle M Hall
Details | Diff | Splinter Review
Bug 10256: Remove some unused subs from Overdues module (13.94 KB, patch)
2013-06-14 08:40 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Marcel de Rooy 2013-05-16 07:53:40 UTC
Did a grep on the following exported subs:

CreateItemAccountLine
UpdateAccountLines
CheckAccountLineLevelInfo
CheckAccountLineItemInfo
CheckExistantNotifyid
GetNextIdNotify
GetNotifyId
ReplacementCost
ReplacementCost2
GetOverdueDelays
GetOverduerules

As it appears, they are not even used anywhere (anymore).
My proposal is now to remove them.
Comment 1 Marcel de Rooy 2013-05-16 08:07:40 UTC Comment hidden (obsolete)
Comment 2 Katrin Fischer 2013-05-16 12:27:14 UTC
Hi Marcel,

I think this is related to a bug I filed - only I was concentrating on the database relicts that are connected to those subs: bug 10021
Comment 3 Marcel de Rooy 2013-05-16 12:46:36 UTC
(In reply to comment #2)
> I think this is related to a bug I filed - only I was concentrating on the
> database relicts that are connected to those subs: bug 10021

Good catch, Katrin. Well, this patch could remove the first code. Your report is somewhat broader in scope.
Comment 4 Kyle M Hall 2013-06-07 16:17:19 UTC Comment hidden (obsolete)
Comment 5 Jonathan Druart 2013-06-14 08:36:47 UTC
QA comment:

I did not find any occurrence of these routines using git grep. So we can suppose that this patch remove unused code and will not break something.

Marked as Passed QA.
Comment 6 Jonathan Druart 2013-06-14 08:40:40 UTC
Created attachment 18978 [details] [review]
Bug 10256: Remove some unused subs from Overdues module

Removes the following exported but unused subs from Overdues.pm:
CreateItemAccountLine
UpdateAccountLines
CheckAccountLineLevelInfo
CheckAccountLineItemInfo
CheckExistantNotifyid
GetNextIdNotify
GetNotifyId
ReplacementCost
ReplacementCost2
GetOverdueDelays
GetOverduerules

Test plan:
It is hard to test the removal of something that was not used :) Try this:
Do a recursive grep on these routine names in the Koha codebase.
Compile some scripts that use the Overdues module.
And just to be sure we do not break something:
Go to Circulation: Do a checkout, checkin, place and confirm a hold.
Go to Patrons: Goto Check out. Goto Fines.
Run the command line scripts: fines.pl and overdue_notices.pl.
Go to opac-user.pl.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Comment 7 Galen Charlton 2013-06-17 16:13:50 UTC
Pushed to master.  Thanks, Marcel!