HTTPS title support, and a minor encoding fix.
parent
5ebe01386d
commit
01cebd1ccc
|
@ -168,7 +168,7 @@ def noteuri(phenny, input):
|
|||
if not hasattr(phenny.bot, 'last_seen_uri'):
|
||||
phenny.bot.last_seen_uri = {}
|
||||
phenny.bot.last_seen_uri[input.sender] = uri
|
||||
noteuri.rule = r'.*(http://[^<> "\x01]+)[,.]?'
|
||||
noteuri.rule = r'.*(http[s]?://[^<> "\x01]+)[,.]?'
|
||||
noteuri.priority = 'low'
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
|
|
@ -46,6 +46,8 @@ def tr(phenny, context):
|
|||
|
||||
if input != output:
|
||||
msg = translate(phrase, input, output)
|
||||
if isinstance(msg, str):
|
||||
msg = msg.decode('utf-8')
|
||||
if msg:
|
||||
msg = web.decode(msg) # msg.replace(''', "'")
|
||||
msg = '"%s" (%s to %s, translate.google.com)' % (msg, input, output)
|
||||
|
|
Loading…
Reference in New Issue