mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-12-24 11:42:52 +01:00
Google: *copy* the utils.web.defaultHeaders before adding items to it.
This commit is contained in:
parent
8e023ed8c6
commit
5341df0254
@ -94,7 +94,7 @@ class Google(callbacks.PluginRegexp):
|
|||||||
if not ref:
|
if not ref:
|
||||||
ref = 'http://%s/%s' % (dynamic.irc.server,
|
ref = 'http://%s/%s' % (dynamic.irc.server,
|
||||||
dynamic.irc.nick)
|
dynamic.irc.nick)
|
||||||
headers = utils.web.defaultHeaders
|
headers = dict(utils.web.defaultHeaders)
|
||||||
headers['Referer'] = ref
|
headers['Referer'] = ref
|
||||||
opts = {'q': query, 'v': '1.0'}
|
opts = {'q': query, 'v': '1.0'}
|
||||||
for (k, v) in options.iteritems():
|
for (k, v) in options.iteritems():
|
||||||
@ -250,7 +250,7 @@ class Google(callbacks.PluginRegexp):
|
|||||||
|
|
||||||
channel = msg.args[0]
|
channel = msg.args[0]
|
||||||
|
|
||||||
headers = utils.web.defaultHeaders
|
headers = dict(utils.web.defaultHeaders)
|
||||||
headers['User-Agent'] = ('Mozilla/5.0 (X11; U; Linux i686) '
|
headers['User-Agent'] = ('Mozilla/5.0 (X11; U; Linux i686) '
|
||||||
'Gecko/20071127 Firefox/2.0.0.11')
|
'Gecko/20071127 Firefox/2.0.0.11')
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user