Bug 20951 - Koha::Patron::Discharge is missing use Koha::Patron::Debarments
Summary: Koha::Patron::Discharge is missing use Koha::Patron::Debarments
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Patrons (show other bugs)
Version: Main
Hardware: All All
: P5 - low major (vote)
Assignee: Fridolin Somers
QA Contact: Testopia
URL:
Keywords:
Depends on: 15548
Blocks: 20953
  Show dependency treegraph
 
Reported: 2018-06-15 10:56 UTC by Fridolin Somers
Modified: 2019-10-14 19:57 UTC (History)
5 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:


Attachments
Bug 20951: add missing use Koha::Patron::Debarments in Koha::Patron::Discharge (1.08 KB, patch)
2018-06-15 11:03 UTC, Fridolin Somers
Details | Diff | Splinter Review
Bug 20951: add missing use Koha::Patron::Debarments in Koha::Patron::Discharge (1.19 KB, patch)
2018-06-19 06:15 UTC, Katrin Fischer
Details | Diff | Splinter Review
Bug 20951: add missing use Koha::Patron::Debarments in Koha::Patron::Discharge (1.22 KB, patch)
2018-06-19 19:07 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 Fridolin Somers 2018-06-15 10:56:09 UTC
Koha::Patron::Discharge is missing use Koha::Patron::Debarments used in discharge() method.
Comment 1 Fridolin Somers 2018-06-15 11:03:53 UTC
Created attachment 76093 [details] [review]
Bug 20951: add missing use Koha::Patron::Debarments in Koha::Patron::Discharge

Koha::Patron::Discharge was missing use Koha::Patron::Debarments used in discharge() method.

Test plan :
1) Enable pref useDischarge
2) Go to OPAC user page
3) Go to 'ask for a discharge' tab
4) Click on 'Ask for a discharge'
5) Go to staff interface : /cgi-bin/koha/members/discharges.pl
6) Click on Allow
=> Without patch you get software error
=> With patch the discharge is validated
Comment 2 Katrin Fischer 2018-06-18 21:29:56 UTC
I can't reproduce the problem. I have tried discharging from the patron account as well as discharging using the link from the dashboard and the 'allow' button.

Similar to bug 20851?
Comment 3 Katrin Fischer 2018-06-19 06:15:54 UTC
Created attachment 76167 [details] [review]
Bug 20951: add missing use Koha::Patron::Debarments in Koha::Patron::Discharge

Koha::Patron::Discharge was missing use Koha::Patron::Debarments used in discharge() method.

Test plan :
1) Enable pref useDischarge
2) Go to OPAC user page
3) Go to 'ask for a discharge' tab
4) Click on 'Ask for a discharge'
5) Go to staff interface : /cgi-bin/koha/members/discharges.pl
6) Click on Allow
=> Without patch you get software error
=> With patch the discharge is validated

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

https://bugs.koha-community.org/show_bug.cgi?id=20953
Comment 4 Jonathan Druart 2018-06-19 19:07:57 UTC
Created attachment 76194 [details] [review]
Bug 20951: add missing use Koha::Patron::Debarments in Koha::Patron::Discharge

Koha::Patron::Discharge was missing use Koha::Patron::Debarments used in discharge() method.

Test plan :
1) Enable pref useDischarge
2) Go to OPAC user page
3) Go to 'ask for a discharge' tab
4) Click on 'Ask for a discharge'
5) Go to staff interface : /cgi-bin/koha/members/discharges.pl
6) Click on Allow
=> Without patch you get software error
=> With patch the discharge is validated

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 5 Nick Clemens 2018-06-22 13:50:08 UTC
Awesome work all!

Pushed to master for 18.11.x
Comment 6 Martin Renvoize 2018-06-25 17:22:17 UTC
Pushed to 18.05.x for 18.05.02
Comment 7 Fridolin Somers 2018-06-28 06:56:28 UTC
(In reply to Katrin Fischer from comment #2)
> I can't reproduce the problem. I have tried discharging from the patron
> account as well as discharging using the link from the dashboard and the
> 'allow' button.
> 
> Similar to bug 20851?

I should have mentioned I'm in Plack env.
I see the explanation in Bug 20851. I think each module should explicitly call use on the modules they need.
Comment 8 Fridolin Somers 2018-06-28 06:56:50 UTC
Pushed to 17.11.x for 17.11.08
Comment 9 Fridolin Somers 2018-09-24 13:22:53 UTC
Pushed to 17.05.x for 17.05.14