FIX: Would cause an error when importing Story Arcs that did not contain a publisher entry, FIX: When attempting to auto-populate the Series for a given story arc (using the search option) would leave one series out which would result in a None value for the Series Year which caused errors when doing a search for watchlist matches.

This commit is contained in:
evilhero 2015-01-04 04:17:49 -05:00
parent 568f0de60c
commit c814e0aa35
2 changed files with 3 additions and 1 deletions

View File

@ -130,7 +130,8 @@ def getComic(comicid,type,issueid=None,arc=None,arcid=None,arclist=None,comicidl
elif type == 'comicyears':
#used by the story arc searcher when adding a given arc to poll each ComicID in order to populate the Series Year.
#this grabs each issue based on issueid, and then subsets the comicid for each to be used later.
dom = pulldetails(arcid,'comicyears',offset=1,comicidlist=comicidlist)
#set the offset to 0, since we're doing a filter.
dom = pulldetails(arcid,'comicyears',offset=0,comicidlist=comicidlist)
return GetSeriesYears(dom)
def GetComicInfo(comicid,dom):

View File

@ -143,6 +143,7 @@ def findComic(name, mode, issue, limityear=None, explicit=None, type=None):
names = len( result.getElementsByTagName('name') )
n = 0
logger.fdebug('length: ' + str(names))
xmlpub = None #set this incase the publisher field isn't populated in the xml
while ( n < names ):
logger.fdebug(result.getElementsByTagName('name')[n].parentNode.nodeName)
if result.getElementsByTagName('name')[n].parentNode.nodeName == 'story_arc':