diff --git a/opac/opac-shelves.pl b/opac/opac-shelves.pl index 87de84acb3..8fa4fb7274 100755 --- a/opac/opac-shelves.pl +++ b/opac/opac-shelves.pl @@ -274,7 +274,8 @@ if ( $op eq 'view' ) { my $contents = $shelf->get_contents->search( {}, { - prefetch => [ { 'biblionumber' => { 'biblioitems' => 'items' } } ], + distinct => 'biblionumber', + join => [ { 'biblionumber' => { 'biblioitems' => 'items' } } ], page => $page, rows => $rows, order_by => { "-$direction" => $order_by },