mirror of
https://github.com/ankitects/anki.git
synced 2025-09-20 23:12:21 -04:00
cloze is blank if no match
This commit is contained in:
parent
57a9668350
commit
35a498b858
1 changed files with 2 additions and 0 deletions
|
@ -196,6 +196,8 @@ class Template(object):
|
|||
|
||||
def clozeText(self, txt, ord, type):
|
||||
reg = clozeReg
|
||||
if not re.search(reg%ord, txt):
|
||||
return ""
|
||||
def repl(m):
|
||||
# replace chosen cloze with type
|
||||
if type == "q":
|
||||
|
|
Loading…
Reference in a new issue