diff --git a/CHANGES.md b/CHANGES.md index 66923c95..d0b5bea3 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -38,6 +38,7 @@ * Change to ensure uTorrent API parameters are ordered for uT 2.2.1 compatibility [develop changelog] +* Change uT params from unicode to str.format as magnet URLs worked but sending files in POST bodies failed ### 0.6.4 (2015-02-10 20:20:00 UTC) diff --git a/sickbeard/clients/utorrent.py b/sickbeard/clients/utorrent.py index 41739cec..010087c7 100644 --- a/sickbeard/clients/utorrent.py +++ b/sickbeard/clients/utorrent.py @@ -35,7 +35,8 @@ class uTorrentAPI(GenericClient): return super(uTorrentAPI, self)._request( method=method, - params='token=%s&%s' % (self.auth, '&'.join([u'%s' % urllib.urlencode(dict([[key, str(value)]])) for key, value in params.iteritems()])) if any(params) else params, + params='token={0:s}&{1:s}'.format(self.auth, '&'.join( + ['%s' % urllib.urlencode(dict([[key, str(value)]])) for key, value in params.iteritems()])) if any(params) else params, files=files) def _get_auth(self):