Bug 9165: (Followup) Tidied code slightly
authorMartin Renvoize <martin.renvoize@ptfs-europe.com>
Thu, 27 Nov 2014 15:31:24 +0000 (15:31 +0000)
committerTomas Cohen Arazi <tomascohen@gmail.com>
Thu, 27 Nov 2014 17:58:46 +0000 (14:58 -0300)
Minor code tidy to clean up qa script warning.

http://bugs.koha-community.org/show_bug.cgi?id=9165
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>

C4/Auth_with_ldap.pm

index ba217fa..a929c04 100644 (file)
@@ -311,11 +311,12 @@ sub _do_changepassword {
         my $sth = C4::Context->dbh->prepare(
             'SELECT cardnumber FROM borrowers WHERE borrowernumber=?');
         $sth->execute($borrowerid);
-        die
-"Unable to access borrowernumber with userid=$userid, borrowernumber=$borrowerid"
+        die "Unable to access borrowernumber "
+            . "with userid=$userid, "
+            . "borrowernumber=$borrowerid"
           if !$sth->rows;
         my ($cardnum) = $sth->fetchrow;
-        my $sth = C4::Context->dbh->prepare(
+        $sth = C4::Context->dbh->prepare(
             'UPDATE borrowers SET password = null WHERE borrowernumber=?');
         $sth->execute($borrowerid);
         return $cardnum;