png: always allow paste.ee raw links
This commit is contained in:
parent
c2dc9632b4
commit
20867834aa
|
@ -691,7 +691,7 @@ class IRCArt(callbacks.Plugin):
|
||||||
ua = UserAgent()
|
ua = UserAgent()
|
||||||
header = {'User-Agent':str(ua.random)}
|
header = {'User-Agent':str(ua.random)}
|
||||||
r = requests.head(url, headers=header)
|
r = requests.head(url, headers=header)
|
||||||
if "text/plain" in r.headers["content-type"]:
|
if "text/plain" in r.headers["content-type"] or url.startswith('https://paste.ee/r/'):
|
||||||
file = requests.get(url, headers=header)
|
file = requests.get(url, headers=header)
|
||||||
else:
|
else:
|
||||||
irc.reply("Invalid file type.", private=False, notice=False)
|
irc.reply("Invalid file type.", private=False, notice=False)
|
||||||
|
|
Loading…
Reference in New Issue