From 4a601416bcd9a45447aa1084f771c5d0ec4b72fe Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Sat, 19 Nov 2011 23:36:40 +0900 Subject: [PATCH] keep typeAns as a field name We have the fact loaded into memory anyway for the q/a display --- anki/upgrade.py | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/anki/upgrade.py b/anki/upgrade.py index 8a57a7324..69e333434 100644 --- a/anki/upgrade.py +++ b/anki/upgrade.py @@ -397,16 +397,6 @@ order by ordinal""", mid)): # q fields now in a if not hideq: conf['afmt'] = conf['qfmt'] + "\n\n
\n\n" + conf['afmt'] - # convert the field name to an ordinal - ordN = None - for (ord, fm) in enumerate(flds): - if fm['name'] == conf['typeAns']: - ordN = ord - break - if ordN is not None: - conf['typeAns'] = ordN - else: - conf['typeAns'] = None for type in ("qfmt", "afmt"): # ensure the new style field format conf[type] = re.sub("%\((.+?)\)s", "{{\\1}}", conf[type])