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.
Created attachment 18165 [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.
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
(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.
Created attachment 18765 [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>
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.
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>
Pushed to master. Thanks, Marcel!