Bug 2346 - consolidate duplicate methods C4::Overdues::UpdateBorrowerDebarred and C4::Members::DebarMember
Summary: consolidate duplicate methods C4::Overdues::UpdateBorrowerDebarred and C4::Me...
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Patrons (show other bugs)
Version: 3.6
Hardware: PC All
: PATCH-Sent (DO NOT USE) normal (vote)
Assignee: Galen Charlton
QA Contact: Jonathan Druart
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-07-11 10:17 UTC by Chris Cormack
Modified: 2013-12-05 20:04 UTC (History)
4 users (show)

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


Attachments
Proposed patch to remove UpdateBorrowerDebarred (2.09 KB, patch)
2011-12-04 17:21 UTC, Ian Walls
Details | Diff | Splinter Review
Bug 2346: Remove C4::Overdues::UpdateBorrowerDebarred in favour of C4::Members::DebarMember (2.14 KB, patch)
2011-12-05 19:57 UTC, Chris Cormack
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Cormack 2010-05-21 00:50:07 UTC


---- Reported by Andrew.moore@liblime.com 2008-07-11 10:17:43 ----

The two methods C4::Overdues::UpdateBorrowerDebarred and C4::Members::DebarMember appear to do the exact same thing. We only need one sub for this. I think this sub belongs in the C4::Members namespace.

Therefore, I'll replace the guts of UpdaetBorrowerDebarred with a call to DebarMember and document that sub as deprecated.



--- Bug imported by chris@bigballofwax.co.nz 2010-05-21 00:50 UTC  ---

This bug was previously known as _bug_ 2346 at http://bugs.koha.org/cgi-bin/bugzilla3/show_bug.cgi?id=2346

Actual time not defined. Setting to 0.0
The original reporter of this bug does not have
   an account here. Reassigning to the person who moved
   it here: chris@bigballofwax.co.nz.
   Previous reporter was Andrew.moore@liblime.com.

Comment 1 Katrin Fischer 2011-04-25 09:11:49 UTC
Is this bug still valid?

I think there were some development for debarment of patrons since this bug was filed.
Comment 2 Ian Walls 2011-12-04 17:16:35 UTC
This issue is resolved with the inclusion of bug 6328.  UpdateBorrowerDebarred has been removed from usage except in the deprecated script notifyMailsOp.pl, and there it is overridden by a local subroutine.  This script has a bug filed against it for removal (bug 7315), so I believe it is safe to remove UpdateBorrowerDebarred from C4::Overdues.  Patch forthcoming.
Comment 3 Ian Walls 2011-12-04 17:21:25 UTC Comment hidden (obsolete)
Comment 4 Chris Cormack 2011-12-05 19:57:55 UTC
Created attachment 6584 [details] [review]
Bug 2346: Remove C4::Overdues::UpdateBorrowerDebarred in favour of C4::Members::DebarMember

Removes now-unused subroutine from C4::Overdues, as well as the db_dependent unit test

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Comment 5 Paul Poulain 2011-12-06 18:15:52 UTC
QA comment: nothing to say, remove dead code.
Digging into this patch to check all UpdateBorrowerDebarred calls were removed showed me that the notifyMailsOp.pl was still here. Added a follow-up to remove this script

Patch pushed, please test
Comment 6 Chris Nighswonger 2011-12-06 19:13:20 UTC
This patch does not apply cleanly to 3.6.x branch. Please rebase over that branch and attach a corrected patch to this bug report.
Comment 7 Jared Camins-Esakov 2012-12-31 00:04:38 UTC
There have been no further reports of problems so I am marking this bug resolved.