diff --git a/plugins/playstation_store.lua b/plugins/playstation_store.lua index 7e4aaaf..c2fcd22 100644 --- a/plugins/playstation_store.lua +++ b/plugins/playstation_store.lua @@ -60,7 +60,7 @@ end return { description = "Zeigt PlayStation Store Infos", usage = "Link zum PlayStation Store", - patterns = {"^https?://store.playstation.com/#!/de%-de/spiel/.*/cid=(.*)$"}, + patterns = {"store.playstation.com/#!/de%-de/spiel/.*/cid=(.*)"}, run = run } diff --git a/plugins/urban_dictionary.lua b/plugins/urban_dictionary.lua index edc0280..0ba6c61 100644 --- a/plugins/urban_dictionary.lua +++ b/plugins/urban_dictionary.lua @@ -5,7 +5,7 @@ local function getUrbanDictionary(term) local res,code = http.request(url) local data = json:decode(res) if code ~= 200 then return "HTTP-Fehler" end - if not data then return "Nichts gefunden!" end + if data.result_type == 'no_results' then return "Nichts gefunden!" end local word = data.list[1].word local dev = data.list[1].definition @@ -15,7 +15,7 @@ local function getUrbanDictionary(term) sound = data.sounds[1] end - local text = unescape(word..'\n'..dev..'\n\nBeispiel: "'..exam..'"\n')..url + local text = unescape(word..'\n'..dev..string.gsub('\n\nBeispiel: "'..exam..'"\n', '""', '"'))..url if data.sounds[1] then return text, sound