# HG changeset patch # User casties # Date 1311069246 -7200 # Node ID 9fb231ad0bd21bfda127d8eb68b23376d8556f39 # Parent b27a7d2f06ff8fae1853de6b8b316835f3f690ab made to work (barely) with Dirks ISMI-Version diff -r b27a7d2f06ff -r 9fb231ad0bd2 documentViewer.py --- a/documentViewer.py Fri Jul 15 21:45:52 2011 +0200 +++ b/documentViewer.py Tue Jul 19 11:54:06 2011 +0200 @@ -656,7 +656,8 @@ logging.debug("documentViewer (getbibinfofromindexmeta) bibmap:"+repr(bibmap)) logging.debug("documentViewer (getbibinfofromindexmeta) bibtype:"+repr(bibtype)) # if there is no mapping bibmap is empty (mapping sometimes has empty fields) - if len(bibmap) > 0 and len(bibmap['author'][0]) > 0 or len(bibmap['title'][0]) > 0: + logging.debug("bibmap: %s"%repr(bibmap)) + if len(bibmap) > 0 and bibmap.get('author',None) or bibmap.get('title',None): try: docinfo['author']=getText(bib.find(bibmap['author'][0])) except: pass