Improved !help feature.
This commit is contained in:
parent
cbdef8e674
commit
31bca36d49
5 changed files with 9 additions and 5 deletions
|
@ -64,7 +64,7 @@ public class CancelPreviousInputHook extends Hook
|
|||
{
|
||||
boolean result;
|
||||
|
||||
if (StringsUtils.containsAnyIgnoreCase(message, "!cancelprevious", "!oops", "!oups"))
|
||||
if (StringsUtils.equalsAnyIgnoreCase(message, "!cancelprevious", "!oops", "!oups"))
|
||||
{
|
||||
logger.info("!cancelprevious/!oops caught.");
|
||||
|
||||
|
|
|
@ -91,7 +91,8 @@ public class HelpHook extends Hook
|
|||
bot.sendMessage(sender, " !fin : terminer la revue en cours");
|
||||
bot.sendMessage(sender, " !stop : abandonner la revue en cours");
|
||||
bot.sendMessage(sender, " ");
|
||||
bot.sendMessage(sender, "Autres commandes : !bonjour, !date, !hello, !licence, !manquants, !merci, !record, !salut, !stats, !version");
|
||||
bot.sendMessage(sender,
|
||||
"Autres commandes : !anniv, !bonjour, !chrono, !date, !hello, !licence, !manquants, !merci, !record, !salut, !stats, !status, !version");
|
||||
|
||||
result = true;
|
||||
}
|
||||
|
|
|
@ -20,6 +20,7 @@ package org.april.hebdobot.bot.hooks;
|
|||
|
||||
import java.io.File;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.april.hebdobot.HebdobotException;
|
||||
import org.april.hebdobot.bot.Hebdobot;
|
||||
import org.april.hebdobot.bot.stats.ReviewDatas;
|
||||
|
@ -68,7 +69,7 @@ public class RecordHook extends Hook
|
|||
{
|
||||
boolean result;
|
||||
|
||||
if (message.equals("!record"))
|
||||
if (StringUtils.equalsIgnoreCase(message, "!record"))
|
||||
{
|
||||
logger.info("!record caught.");
|
||||
|
||||
|
|
|
@ -20,6 +20,7 @@ package org.april.hebdobot.bot.hooks;
|
|||
|
||||
import java.io.File;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.april.hebdobot.HebdobotException;
|
||||
import org.april.hebdobot.bot.Hebdobot;
|
||||
import org.april.hebdobot.bot.stats.ReviewDatas;
|
||||
|
@ -68,7 +69,7 @@ public class StatsHook extends Hook
|
|||
{
|
||||
boolean result;
|
||||
|
||||
if (message.equals("!stats"))
|
||||
if (StringUtils.equalsIgnoreCase(message, "!stats"))
|
||||
{
|
||||
logger.info("!stats caught.");
|
||||
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
*/
|
||||
package org.april.hebdobot.bot.hooks;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.april.hebdobot.HebdobotException;
|
||||
import org.april.hebdobot.bot.Hebdobot;
|
||||
import org.april.hebdobot.util.BuildInformation;
|
||||
|
@ -64,7 +65,7 @@ public class VersionHook extends Hook
|
|||
{
|
||||
boolean result;
|
||||
|
||||
if (message.equals("!version"))
|
||||
if (StringUtils.equalsIgnoreCase(message, "!version"))
|
||||
{
|
||||
logger.info("!version caught.");
|
||||
bot.sendMessage(new BuildInformation().toString());
|
||||
|
|
Loading…
Reference in a new issue