@@ -, +, @@ commit e1b5fa657de843a177fb4bf57947a1376152d021 Bug 14385: Squash of a lot of patches rebased - Have the OPAC tags feature enabled - Add a couple tags to different records, make sure some of them are - Go to 'Tag cloud' in the OPAC --- opac/opac-tags.pl | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) --- a/opac/opac-tags.pl +++ a/opac/opac-tags.pl @@ -307,6 +307,7 @@ if ($add_op) { $results = get_approval_rows($arghash); my @filtered_results; foreach my $my_tag (@$my_tags) { + next if grep {/^$my_tag$/} @filtered_results; if (grep { $_->{term} eq $my_tag->{term} } @$results) { if (! $my_tag->{visible} ) { my $check_biblio = GetMarcBiblio({ @@ -314,12 +315,9 @@ if ($add_op) { embed_items => 1, opac => 1, borcat => $borcat }); - if ($check_biblio) { - push @filtered_results, $my_tag; - } - } else { - push @filtered_results, $my_tag; + next unless $check_biblio; } + push @filtered_results, $my_tag; } } $results = \@filtered_results; --