REGRESSION: keyword triggers when it is not the only word in the message
REGRESSION: keyword triggers when it is not the only word in the message
| Issue ID: | 3052 |
| Issue Category: | bug |
| Component: | core |
| Priority: | major |
| Status: | fixed |
| Assigned: | brion |
| Version: | 0.9 |
I tried posting the following message: "help us find the new !KDE CWG members http://blog.lydiapintscher.de/2011/02/18/cwg-call-for-nominations-and-next-office-hour/"
My client (choqok) said it was posted but it did not show up on the website. Then I tried posting it on the website and it did not get posted either but instead showed a message starting with: "Commands: on - turn on notifications off - turn off notifications help - show this help follow - subscribe to user groups - lists the groups you have joined subscriptions - list the people you follow subscribers".
Evan said the problem is that the help keyword gets triggered but should not be triggered if help is not the only word in the message.

Updates
#1
Confirming that this did not happen in 0.9.6 ... tracking it down.
#2
Processing appears to have changed in this commit, labeled as adding hooks for command processing:
http://www.gitorious.org/statusnet/mainline/commit/21feac3bea72b0ecd88a3...
#3
Looks like this is the culprit:
41 if ($arg) {
42 $result = null;
43 }
44 $result = new HelpCommand($user);
45 break;
The code for the 'help' command is supposed to ignore the command if there's additional input, but the logic was restructured incorrectly when switching from multiple return locations to a single return location. Should be an easy fix.
#4
Fixed on master:
eb7e3ee Fixes for ticket #3052: some commands started triggering when extra text is supp
11e033f CommandInterpreter test cases to guard against regressions
You can also subscribe to the
RSS feed for updates to this issue.