diff --git a/docs/changelog/7.x.x.txt b/docs/changelog/7.x.x.txt index 7f61eb98d..22aee34a1 100644 --- a/docs/changelog/7.x.x.txt +++ b/docs/changelog/7.x.x.txt @@ -1,7 +1,7 @@ 7.4.6 + - Prevent Help index from trying to link to non-existant documentation - fix: can't see the send private message link - 7.4.5 - fix: Apostrophy incorrectly escaped as double quote in some places - Remove Help TOC links diff --git a/lib/WebGUI/Operation/Help.pm b/lib/WebGUI/Operation/Help.pm index 2644392ac..6757dac37 100644 --- a/lib/WebGUI/Operation/Help.pm +++ b/lib/WebGUI/Operation/Help.pm @@ -389,21 +389,20 @@ sub www_viewHelpIndex { return $session->privilege->insufficient() unless canView($session); my $i18n = WebGUI::International->new($session); my @helpIndex; - my $i; my @files = _getHelpFilesList($session,); foreach my $fileSet (@files) { my $namespace = $fileSet->[1]; my $help = _load($session,$namespace); foreach my $key (keys %{$help}) { next if $help->{$key}{private}; - push @helpIndex, [$namespace, $key, - $i18n->get($help->{$key}{title},$namespace)]; - $i++; + my $title = $i18n->get($help->{$key}{title},$namespace); + next unless $title; + push @helpIndex, [$namespace, $key, $title]; } } my $output = '
| '; - my $halfway = round($i/2); - $i = 0; + my $halfway = round(@helpIndex / 2); + my $i = 0; @helpIndex = sort { $a->[2] cmp $b->[2] } @helpIndex; foreach my $helpEntry (@helpIndex) { my ($namespace, $id, $title) = @{ $helpEntry }; |