Check the snatched db first for the folder name when forcing post-processing

This commit is contained in:
rembo10
2012-11-06 18:07:46 -05:00
parent e545fead2a
commit b0fa43e5b9

View File

@@ -818,6 +818,15 @@ def forcePostProcess():
logger.info('Processing: %s' % folder_basename)
# First try to see if there's a match in the snatched table, then we'll try to parse the foldername
snatched = myDB.action('SELECT AlbumID, Title from snatched WHERE FolderName LIKE ?', [folder_basename])
if snatched:
logger.info('Found a match in the database: %s. Verifying to make sure it is the correct album' % snatched['Title'])
verify(snatched['AlbumID'], folder)
continue
# Try to parse the folder name into a valid format
# TODO: Add metadata lookup
try:
name, album, year = helpers.extract_data(folder_basename)
except: