Fix SabNZBd folder bug
If only one file is extracted the storage key contains the extracted file instead of the folder. This leads to CPS skipping the renamer. This check fixes that.
This commit is contained in:
@@ -6,6 +6,7 @@ from couchpotato.environment import Env
|
||||
from datetime import timedelta
|
||||
from urllib2 import URLError
|
||||
import json
|
||||
import os
|
||||
import traceback
|
||||
|
||||
log = CPLog(__name__)
|
||||
@@ -117,7 +118,7 @@ class Sabnzbd(Downloader):
|
||||
'status': status,
|
||||
'original_status': nzb['status'],
|
||||
'timeleft': str(timedelta(seconds = 0)),
|
||||
'folder': ss(nzb['storage']),
|
||||
'folder': os.path.dirname(ss(nzb['storage'])) if os.path.isfile(ss(nzb['storage'])) else ss(nzb['storage']),
|
||||
})
|
||||
|
||||
return release_downloads
|
||||
|
||||
Reference in New Issue
Block a user