mirror of
https://github.com/clinton-hall/nzbToMedia.git
synced 2025-08-21 13:53:15 -07:00
Fixed a bug in the minSize function, was backwards so it never returned results when media files existed.
This commit is contained in:
parent
c0f61ecb2d
commit
817f310169
4 changed files with 10 additions and 17 deletions
|
@ -77,16 +77,7 @@ class autoProcessTV:
|
|||
inputName, dirName = convert_to_ascii(inputName, dirName)
|
||||
|
||||
# Now check if tv files exist in destination. Eventually extraction may be done here if nzbExtractionBy == TorrentToMedia
|
||||
video = 0
|
||||
for dirFile in listMediaFiles(dirName):
|
||||
fullFileName = os.path.basename(dirFile)
|
||||
fileName, fileExt = os.path.splitext(fullFileName)
|
||||
|
||||
if fileExt in nzbtomedia.MEDIACONTAINER:
|
||||
logger.debug("Found media file: %s" % (fullFileName))
|
||||
video += 1
|
||||
|
||||
if video > 0: # Check that a video exists. if not, assume failed.
|
||||
if listMediaFiles(dirName): # Check that a video exists. if not, assume failed.
|
||||
flatten(dirName) # to make sure SickBeard can find the video (not in sub-folder)
|
||||
elif clientAgent == "manual":
|
||||
logger.warning("No media files found in directory %s to manually process." % (dirName), section)
|
||||
|
@ -94,7 +85,7 @@ class autoProcessTV:
|
|||
else:
|
||||
logger.warning("No media files found in directory %s. Processing this as a failed download" % (dirName), section)
|
||||
status = 1
|
||||
failed = True
|
||||
failed = 1
|
||||
|
||||
# configure SB params to pass
|
||||
fork_params['quiet'] = 1
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue