Launch-Bugfixes!

- Cats sendet wieder
- About: /start als Pattern
- Shell: return vergessen
This commit is contained in:
Andreas Bielawski 2016-06-21 16:20:56 +02:00
parent 89ff787b09
commit fc7e0d46f9
4 changed files with 7 additions and 11 deletions

View File

@ -197,11 +197,8 @@ end
function create_plugin_set() function create_plugin_set()
enabled_plugins = { enabled_plugins = {
'control', 'control',
'blacklist',
'about', 'about',
'ping', 'id',
'whoami',
'nick',
'echo', 'echo',
'imgblacklist', 'imgblacklist',
'gImages', 'gImages',
@ -213,12 +210,9 @@ function create_plugin_set()
'urbandictionary', 'urbandictionary',
'time', 'time',
'reddit', 'reddit',
'reddit_post',
'xkcd', 'xkcd',
'slap',
'commit',
'pun',
'currency', 'currency',
'shout',
'set', 'set',
'get', 'get',
'patterns', 'patterns',

View File

@ -7,7 +7,8 @@ about.command = 'about'
about.doc = '`Sendet Informationen über den Bot.`' about.doc = '`Sendet Informationen über den Bot.`'
about.triggers = { about.triggers = {
'/about' '/about',
'/start'
} }
function about:action(msg, config) function about:action(msg, config)

View File

@ -27,11 +27,11 @@ local apikey = cred_data.cat_apikey or "" -- apply for one here: http://thecatap
function cats:action(msg, config) function cats:action(msg, config)
if matches[1] == 'gif' then if matches[1] == 'gif' then
local url = 'http://thecatapi.com/api/images/get?type=gif&apikey='..apikey local url = 'http://thecatapi.com/api/images/get?type=gif&apikey='..apikey
local file = download_to_file(url) local file = download_to_file(url, 'miau.gif')
utilities.send_document(self, msg.chat.id, file, nil, msg.message_id) utilities.send_document(self, msg.chat.id, file, nil, msg.message_id)
else else
local url = 'http://thecatapi.com/api/images/get?type=jpg,png&apikey='..apikey local url = 'http://thecatapi.com/api/images/get?type=jpg,png&apikey='..apikey
local file = download_to_file(url) local file = download_to_file(url, 'miau.png')
utilities.send_photo(self, msg.chat.id, file, nil, msg.message_id) utilities.send_photo(self, msg.chat.id, file, nil, msg.message_id)
end end
end end

View File

@ -10,6 +10,7 @@ function shell:action(msg, config)
if msg.from.id ~= config.admin then if msg.from.id ~= config.admin then
utilities.send_reply(self, msg, config.errors.sudo) utilities.send_reply(self, msg, config.errors.sudo)
return
end end
local input = utilities.input(msg.text) local input = utilities.input(msg.text)