From f64c8f25d2d56e862b71cc430e5adc8736c6ba95 Mon Sep 17 00:00:00 2001 From: Akamaru Date: Fri, 31 Jul 2015 18:01:10 +0200 Subject: [PATCH] something --- .gitignore | 4 +++- plugins/images.lua | 2 +- plugins/url_title.lua | 1 + 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index e227398..0a5a69f 100644 --- a/.gitignore +++ b/.gitignore @@ -46,4 +46,6 @@ plugins/flickr.lua plugins/flickr_search.lua plugins/google_books.lua plugins/safebrowsing.lua -plugins/stats2.lua \ No newline at end of file +plugins/stats2.lua +plugins/help2.lua +plugins/miiverse.lua \ No newline at end of file diff --git a/plugins/images.lua b/plugins/images.lua index c10afa0..9541474 100644 --- a/plugins/images.lua +++ b/plugins/images.lua @@ -10,7 +10,7 @@ end return { description = "Wenn ein Link zu einem Bild gesendet wird, läd und sendet der Bot das Bild.", usage = {"Link zum Bild"}, - patterns = {"(https?://[%w-_%.%?%.:/%+=&]+%.png)$","(https?://[%w-_%.%?%.:/%+=&]+%.jpg)$","(https?://[%w-_%.%?%.:/%+=&]+%.jpeg)$",}, + patterns = {"^(https?://[%w-_%.%?%.:/%+=&]+%.png)$","^(https?://[%w-_%.%?%.:/%+=&]+%.jpg)$","^(https?://[%w-_%.%?%.:/%+=&]+%.jpeg)$",}, run = run } diff --git a/plugins/url_title.lua b/plugins/url_title.lua index 3b8c774..af7b1ff 100644 --- a/plugins/url_title.lua +++ b/plugins/url_title.lua @@ -15,6 +15,7 @@ function getTitle(page) s = string.gsub(s, "'", "'") s = string.gsub(s, "–", "–") s = string.gsub(s, "»", "»") + s = string.gsub(s, "–", "–") s = string.gsub(s, "“", "“") s = string.gsub(s, "”", "”") s = string.gsub(s, "ä", "ä")