make help module give the topics for that module. fixes bug 145369.

This commit is contained in:
ian%hixie.ch 2003-08-16 19:45:43 +00:00
Родитель 5ecacbf785
Коммит 685d9c3233
1 изменённых файлов: 5 добавлений и 0 удалений

Просмотреть файл

@ -41,8 +41,13 @@ sub Told {
foreach my $module (@modules) {
my $commands = $module->Help($event);
if ($commands->{''}) {
my @commands = grep { /./os } keys %$commands;
$topicList{lc($module->{'_name'})} = [] unless defined($topicList{lc($module->{'_name'})});
push(@{$topicList{lc($module->{'_name'})}}, $commands->{''});
if (@commands) {
local $" = ', ';
push(@{$topicList{lc($module->{'_name'})}}, "The $module->{'_name'} module has the following help topics: @commands");
}
}
foreach (keys %$commands) {
$topicList{lc($_)} = [] unless defined($topicList{lc($_)});