1
0
mirror of https://github.com/moparisthebest/SickRage synced 2024-11-15 13:55:05 -05:00

Fix for uTorrent 2.2.1 token order.

Put the token in first place.
See https://github.com/SiCKRAGETV/sickrage-issues/issues/483 for more
info.
This commit is contained in:
Alexandre Beloin 2015-02-02 16:13:29 -05:00
parent c62d8f2c79
commit 0ae4384f33

View File

@ -32,8 +32,14 @@ class uTorrentAPI(GenericClient):
def _request(self, method='get', params={}, files=None): def _request(self, method='get', params={}, files=None):
params.update({'token': self.auth}) #Workaround for uTorrent 2.2.1
return super(uTorrentAPI, self)._request(method=method, params=params, files=files) #Need a odict but only supported in 2.7+ and sickrage is 2.6+
ordered_params = {'token': self.auth}
for k,v in params.iteritems():
ordered_params.update({k: v})
return super(uTorrentAPI, self)._request(method=method, params=ordered_params, files=files)
def _get_auth(self): def _get_auth(self):