From: Chris Nighswonger <[EMAIL PROTECTED]>
Signed-off-by: Galen Charlton <[EMAIL PROTECTED]>
---
C4/VirtualShelves/Page.pm | 11 +++++++----
1 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/C4/VirtualShelves/Page.pm b/C4/VirtualShelves/Page.pm
index 37ff28a..8b219ff 100755
--- a/C4/VirtualShelves/Page.pm
+++ b/C4/VirtualShelves/Page.pm
@@ -129,6 +129,7 @@ SWITCH: {
ModShelf( $shelfnumber, $shelf );
$shelflist = GetShelves( $loggedinuser, 2 ); #
refresh after mods
+
} elsif ( $op eq 'modif' ) {
my ( $shelfnumber2, $shelfname, $owner, $category,
$sortfield ) =GetShelf( $shelfnumber );
$template->param(
@@ -271,10 +272,12 @@ if ($template->param( 'shelves' ) or
my $sessionID = $query->cookie("CGISESSID") ;
my $session = get_session($sessionID);
-my $shelves = GetShelvesSummary($loggedinuser, 2, 10);
-$session->param('shelves', $shelves);
-$template->param( barshelves => scalar (@$shelves));
-$template->param( barshelvesloop => $shelves);
+my $barshelves = GetShelvesSummary($loggedinuser, 2, 10);
+if (defined($barshelves)) {
+ $session->param('barshelves', $barshelves);
+ $template->param( barshelves => scalar (@$barshelves));
+ $template->param( barshelvesloop => $barshelves);
+}
output_html_with_http_headers $query, $cookie, $template->output;
}
--
1.5.5.GIT
_______________________________________________
Koha-patches mailing list
[email protected]
http://lists.koha.org/mailman/listinfo/koha-patches