Fixed bugs in autoProcessMusic and autoProcessMovie

This commit is contained in:
echel0n 2014-04-13 13:20:39 -07:00
commit eeee92c830
2 changed files with 10 additions and 1 deletions

View file

@ -172,6 +172,10 @@ class autoProcessMovie:
media_id, download_id, release_id, release_status = self.find_media_id(baseURL, download_id, dirName, nzbName) # get the CPS database movie id for this movie.
if release_status is None:
logger.error("Could not find a current status for %s on CouchPotatoServer", nzbName)
return 1
# failed to get a download id
if release_status != "snatched":
logger.postprocess("%s has is marked with a status of [%s] by CouchPotatoServer, skipping ...", nzbName, release_status.upper())

View file

@ -88,9 +88,14 @@ class autoProcessMusic:
url = baseURL
release_status = self.get_status(url, apikey, dirName)
if release_status is None:
logger.error("Could not find a current status for %s on HeadPhones", nzbName)
return 1
if release_status != "Unprocessed":
logger.error("%s is marked with a status of %s on HeadPhones, skipping ...", nzbName, release_status)
return 1
return 0
logger.debug("Opening URL: %s", url)