diff options
-rw-r--r-- | dfr/dump2msgp.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/dfr/dump2msgp.py b/dfr/dump2msgp.py index 7e355c7..0867a87 100644 --- a/dfr/dump2msgp.py +++ b/dfr/dump2msgp.py @@ -44,8 +44,8 @@ if __name__ == '__main__': from sectionList import listInfoSection from template import template else: - from dfr.sectionList import listInfoSection - from dfr.template import template + from sectionList import listInfoSection + from template import template dictMatch = {x['match']: i for (i, x) in enumerate(listInfoSection)} @@ -216,7 +216,8 @@ def extract(f, w, errorF): p1 += 2 p = line[p0:p1] p = p.split('|') - info['API'] = p[1] + if len(p) > 2: + info['API'] = p[1] if '{{m}}' in line: info['genre'] = 'mas' elif '{{f}}' in line: |