Merge remote-tracking branch 'upstream/master'

This commit is contained in:
Andreas Bielawski 2016-08-25 14:37:53 +02:00
commit 2d3421ff61
2 changed files with 8 additions and 7 deletions

View File

@ -1,6 +1,6 @@
local about = {} local about = {}
local bot = require('miku.bot') local bot = require('otouto.bot')
about.command = 'about' about.command = 'about'
about.doc = '`Sendet Informationen über den Bot.`' about.doc = '`Sendet Informationen über den Bot.`'
@ -8,13 +8,13 @@ about.doc = '`Sendet Informationen über den Bot.`'
function about:init(config) function about:init(config)
about.text = config.about_text .. '\n[Mikudayobot](https://github.com/Akamaru/Mikubot-V2) v'..bot.version..' von @Akamaru, basierend auf [otouto](https://github.com/topkecleon/otouto) von topkecleon.' about.text = config.about_text .. '\n[Mikudayobot](https://github.com/Akamaru/Mikubot-V2) v'..bot.version..' von @Akamaru, basierend auf [otouto](https://github.com/topkecleon/otouto) von topkecleon.'
about.triggers = { about.triggers = {
'/[Aa][Bb][Oo][Uu][Tt]', '^/about$',
'/[Ss][Tt][Aa][Rr][Tt]' '^/start$'
} }
end end
function about:action(msg, config) function about:action(msg, config)
utilities.send_message(msg.chat.id, about.text, true, nil, true) utilities.send_message(msg.chat.id, about.text, true, nil, true)
end end
return about return about

View File

@ -9,7 +9,8 @@ function help:init(config)
"^/[Hh][Ii][Ll][Ff][Ee] (.+)", "^/[Hh][Ii][Ll][Ff][Ee] (.+)",
"^/[Hh][Ee][Ll][Pp] (.+)", "^/[Hh][Ee][Ll][Pp] (.+)",
"^/(hilfe)_(.+)", "^/(hilfe)_(.+)",
"^/[Hh][Ii][Ll][Ff][Ee]$" "^/hilfe$",
"^/help$"
} }
help.inline_triggers = { help.inline_triggers = {
"^[Hh][Ii][Ll][Ff][Ee] (.+)", "^[Hh][Ii][Ll][Ff][Ee] (.+)",
@ -37,7 +38,7 @@ end
function help:action(msg, config, matches) function help:action(msg, config, matches)
if matches[2] then if matches[2] then
input = matches[2] input = matches[2]
elseif matches[1] ~= '/hilfe' then elseif matches[1] ~= '/hilfe' and matches[1] ~= '/help' then
input = matches[1] input = matches[1]
else else
input = nil input = nil