From 59e7cb32d663ce1718cb948ae313ca02123b8935 Mon Sep 17 00:00:00 2001 From: mutantmonkey Date: Sun, 6 Mar 2016 14:36:41 -0800 Subject: [PATCH] translate: switch to https --- modules/translate.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/translate.py b/modules/translate.py index 7d26573..3dee81a 100644 --- a/modules/translate.py +++ b/modules/translate.py @@ -28,7 +28,7 @@ def translate(text, input='auto', output='en'): output = web.quote(output.encode('utf-8')) text = web.quote(text.encode('utf-8')) - result = web.get('http://translate.google.com/translate_a/t?' + + result = web.get('https://translate.google.com/translate_a/t?' + ('client=t&hl=en&sl=%s&tl=%s&multires=1' % (input, output)) + ('&otf=1&ssel=0&tsel=0&uptl=en&sc=1&text=%s' % text))