hook_help implementations sometimes return an empty string when there is no help - e.g. pathauto_help(), actions_help(), but these get added to the array when hook_help is invoked via module_invoke_all() as in bot.module, resulting in "empty" features being listed, e.g. (22:09:11) Druplicon_tmp: Detailed information is available by asking for "help <feature>" where <feature> is one of: , Botagotchi, Drupal URLs, Factoids, Function Lookups, Seen. (note the comma at the start of the feature list)

CommentFileSizeAuthor
#2 bot-help_0.patch2.22 KBjohn morahan
#1 bot-help.patch2.22 KBjohn morahan

Comments

john morahan’s picture

Status: Active » Needs review
StatusFileSize
new2.22 KB
john morahan’s picture

StatusFileSize
new2.22 KB

typo

morbus iff’s picture

This is actually a bug in those modules, not in bot.module. Both actions.module and pathauto.module always preinit $output to '' (as opposed to NULL) and always return $output, regardless if the module help properly fires. This is not something that any of the core modules do, and is bad design. Akismet.module does it also. Whilst I agree that your fix would get rid of these errors, I don't find them MY errors to get rid of - they should be fixed in the source module (and I heartily will support you creating issues in their queues that refer to this explanation).

morbus iff’s picture

This also occurs with the triggers.module of Drupal 6 (which is actions.module in disguise).

morbus iff’s picture

john morahan’s picture

I agree it is bad design. I guess the reason it doesn't come up, is that help.module itself doesn't breaks when this happens, due to the unusual ways it invokes this hook.

Okay, off I go to create more bug reports.

john morahan’s picture

Status: Needs review » Fixed

This is now fixed in pathauto and actions, still waiting for akismet but I guess nothing more needs to be done here.

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.

morbus iff’s picture

Status: Closed (fixed) » Active

Reopening. I should probably do this cos people aren't learning.

morbus iff’s picture

Version: 5.x-1.x-dev » 6.x-1.x-dev
Status: Active » Fixed

Fixed in DRUPAL-6--1. Thanks!

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.