prove t/db_dependent/ILSDI_Services.t
generates noisy output as a result of the ambiguous context
of two $cgi->param() calls.
By storing into scalar variables, and then using the scalar
variables, the code maintains readability and fixes the problem.
TEST PLAN
---------
1) prove t/db_dependent/ILSDI_Services.t
-- noisy.
2) apply patch
3) prove t/db_dependent/ILSDI_Services.t
-- not noisy
4) run koha qa test tools
Signed-off-by: Marc <veron@veron.ch>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
sub AuthenticatePatron {
my ($cgi) = @_;
- my ($status, $cardnumber, $userid) = C4::Auth::checkpw( C4::Context->dbh, $cgi->param('username'), $cgi->param('password') );
+ my $username = $cgi->param('username');
+ my $password = $cgi->param('password');
+ my ($status, $cardnumber, $userid) = C4::Auth::checkpw( C4::Context->dbh, $username, $password );
if ( $status ) {
# Get the borrower
my $borrower = GetMember( cardnumber => $cardnumber );