Skip to content

Commit

Permalink
Change remove required restart of SickGear after changing label or pa…
Browse files Browse the repository at this point in the history
…th settings for rTorrent and qBittorrent.
  • Loading branch information
JackDandy committed Nov 15, 2018
1 parent f92bc48 commit 1ae2bd3
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 9 deletions.
7 changes: 6 additions & 1 deletion CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
### 0.17.13 (2018-11-08 21:12:00 UTC)
### 0.17.14 (2018-11-15 08:00:00 UTC)

* Change remove required restart of SickGear after changing label or path settings for rTorrent and qBittorrent


### 0.17.13 (2018-11-08 21:12:00 UTC)

* Fix add filter to data used for alternative scene episode numbers
* Change don't enable "Scene numbering" for shows without alternative scene episode numbers
Expand Down
7 changes: 4 additions & 3 deletions sickbeard/clients/qbittorrent.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
# You should have received a copy of the GNU General Public License
# along with SickGear. If not, see <http://www.gnu.org/licenses/>.

from sickbeard import helpers, TORRENT_LABEL, TORRENT_PATH
import sickbeard
from sickbeard import helpers
from sickbeard.clients.generic import GenericClient


Expand Down Expand Up @@ -43,8 +44,8 @@ def _post_api(self, cmd='', **kwargs):

def _add_torrent(self, cmd, **kwargs):

label = TORRENT_LABEL.replace(' ', '_')
label_dict = {'label': label, 'category': label, 'savepath': TORRENT_PATH}
label = sickbeard.TORRENT_LABEL.replace(' ', '_')
label_dict = {'label': label, 'category': label, 'savepath': sickbeard.TORRENT_PATH}
if 'post_data' in kwargs:
kwargs['post_data'].update(label_dict)
else:
Expand Down
11 changes: 6 additions & 5 deletions sickbeard/clients/rtorrent.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@
# along with SickGear. If not, see <http://www.gnu.org/licenses/>.

import xmlrpclib
from sickbeard import helpers, TORRENT_LABEL, TORRENT_PATH
import sickbeard
from sickbeard import helpers
from sickbeard.clients.generic import GenericClient
from lib.rtorrent import RTorrent

Expand Down Expand Up @@ -58,11 +59,11 @@ def _add_torrent(self, cmd, **kwargs):

if torrent:

if TORRENT_LABEL:
torrent.set_custom(1, TORRENT_LABEL)
if sickbeard.TORRENT_LABEL:
torrent.set_custom(1, sickbeard.TORRENT_LABEL)

if TORRENT_PATH:
torrent.set_directory(TORRENT_PATH)
if sickbeard.TORRENT_PATH:
torrent.set_directory(sickbeard.TORRENT_PATH)

torrent.start()

Expand Down

0 comments on commit 1ae2bd3

Please sign in to comment.