mirror of
https://github.com/moparisthebest/SickRage
synced 2025-01-08 04:18:09 -05:00
Merge pull request #1282 from abeloin/patch-utorrent_token
Fix for uTorrent 2.2.1 token order.
This commit is contained in:
commit
5dfff06417
@ -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):
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user