summaryrefslogtreecommitdiff
path: root/data/rbot
diff options
context:
space:
mode:
authorM. Hecker <apoc@sixserv.org>2014-11-28 14:59:43 +0100
committerM. Hecker <apoc@sixserv.org>2014-11-28 14:59:43 +0100
commit633fdf34ed152f06b123e7b3167177bf385f49bb (patch)
tree0201fd8e64ec23364c065ba6ae2eefb48b4f611e /data/rbot
parenteb90a5ebff4da23a9ac1f35bf90bfa3004599bf2 (diff)
[translator] fixes broken page encoding
Diffstat (limited to 'data/rbot')
-rw-r--r--data/rbot/plugins/translator.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/data/rbot/plugins/translator.rb b/data/rbot/plugins/translator.rb
index 33821638..833701c3 100644
--- a/data/rbot/plugins/translator.rb
+++ b/data/rbot/plugins/translator.rb
@@ -128,6 +128,7 @@ class GoogleTranslator < Translator
def do_translate(text, from, to)
agent = Mechanize.new
+ agent.user_agent_alias = 'Linux Mozilla'
page = agent.get URL
form = page.form_with(:id => 'gt-form')
form.sl = from