FIX missing import in files.

main
Olivier Mangin 12 years ago
parent 2209ee6dc1
commit 70eec18c1d

@ -48,7 +48,7 @@ def test_paper(query_string, p):
if field in ['labels', 'l', 'tags', 't']: if field in ['labels', 'l', 'tags', 't']:
if value not in p.metadata['labels']: if value not in p.metadata['labels']:
return False return False
elif field in ['authors', 'a']: # that is the very ugly elif field in ['author', 'authors', 'a']: # that is the very ugly
if not 'author' in p.bibentry.persons: if not 'author' in p.bibentry.persons:
return False return False
a = False a = False
@ -56,10 +56,9 @@ def test_paper(query_string, p):
if value in p.last()[0]: if value in p.last()[0]:
a = True a = True
return a return a
else: elif field in p.bibentry.fields:
if field in p.bibentry.fields:
if value not in p.bibentry.fields[field]: if value not in p.bibentry.fields[field]:
return False return False
else: else:
return False return False
return True return True

@ -6,6 +6,7 @@ import yaml
from . import ui from . import ui
from . import configs from . import configs
from . import color
try: try:
import pybtex import pybtex

Loading…
Cancel
Save