Bug 28600: Resolve variable scope issue
authorTomas Cohen Arazi <tomascohen@theke.io>
Fri, 18 Jun 2021 18:20:30 +0000 (15:20 -0300)
committerKyle M Hall <kyle@bywatersolutions.com>
Thu, 24 Jun 2021 14:12:09 +0000 (10:12 -0400)
commit4563a75c3576f08d370e089e4d3de288464930d3
tree39902647595e134bd755335e16c3d215b058ca8d
parent343bf361e0417f10f79daff767c38c076d039b23
Bug 28600: Resolve variable scope issue

This patch fixes a scope issue. Originally, a variable declared as

our $borcat

was replaced by

my $patron

This patch makes the method not rely on global variables, but have a
parameter for the patron, and thus things are clearer.

To test:
1. Open the OPAC detail page for a record
=> FAIL: The logs show some errors about the $patron variable not
available in the scope
2. Apply this patch
3. Repeat 1
=> SUCCESS: No errors
4. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
opac/opac-detail.pl