diff --git a/opac/opac-shelves.pl b/opac/opac-shelves.pl index 237ad91cf1..3240506cf9 100755 --- a/opac/opac-shelves.pl +++ b/opac/opac-shelves.pl @@ -108,12 +108,12 @@ if ( $op eq 'add_form' ) { my $sortfield = $query->param('sortfield'); $sortfield = 'title' unless grep {/^$sortfield$/}qw( title author copyrightdate itemcallnumber ); if ( $shelf->can_be_managed( $loggedinuser ) ) { - $shelf->shelfname( $query->param('shelfname') ); + $shelf->shelfname( scalar $query->param('shelfname') ); $shelf->sortfield( $sortfield ); - $shelf->allow_add( $query->param('allow_add') ); - $shelf->allow_delete_own( $query->param('allow_delete_own') ); - $shelf->allow_delete_other( $query->param('allow_delete_other') ); - $shelf->category( $query->param('category') ); + $shelf->allow_add( scalar $query->param('allow_add') ); + $shelf->allow_delete_own( scalar $query->param('allow_delete_own') ); + $shelf->allow_delete_other( scalar $query->param('allow_delete_other') ); + $shelf->category( scalar $query->param('category') ); eval { $shelf->store }; if ($@) {