diff --git a/otouto/plugins/translate.lua b/otouto/plugins/translate.lua index a80cb9f..f9e8427 100644 --- a/otouto/plugins/translate.lua +++ b/otouto/plugins/translate.lua @@ -10,6 +10,11 @@ require("./otouto/plugins/pasteee") translate.command = 'translate [Text]' function translate:init(config) + if not cred_data.bing_key then + print('Missing config value: bing_key.') + print('translate.lua will not be enabled.') + return + end translate.triggers = { "^/translate ([%w]+),([%a]+) (.+)", "^/translate (to%:)([%w]+) (.+)", diff --git a/otouto/plugins/wikipedia.lua b/otouto/plugins/wikipedia.lua index 5d2d326..7a45519 100644 --- a/otouto/plugins/wikipedia.lua +++ b/otouto/plugins/wikipedia.lua @@ -209,7 +209,7 @@ function wikipedia:action(msg, config, matches) lang = nil end if term == "" then - utilities.send_reply(msg, self, wikipedia.doc) + utilities.send_reply(self, msg, wikipedia.doc) return end