mirror of
https://github.com/ankitects/anki.git
synced 2025-09-24 08:46:37 -04:00
allow multiple spaces in type answer
This commit is contained in:
parent
952f0cf6bd
commit
e6ecbfd086
1 changed files with 3 additions and 0 deletions
|
@ -391,7 +391,10 @@ Please run Tools>Empty Cards""")
|
|||
# munge correct value
|
||||
parser = HTMLParser.HTMLParser()
|
||||
cor = stripHTML(self.mw.col.media.strip(self.typeCorrect))
|
||||
# ensure we don't chomp multiple whitespace
|
||||
cor = cor.replace(" ", " ")
|
||||
cor = parser.unescape(cor)
|
||||
cor = cor.replace(u"\xa0", " ")
|
||||
given = self.typedAnswer
|
||||
# compare with typed answer
|
||||
res = self.correct(given, cor, showBad=False)
|
||||
|
|
Loading…
Reference in a new issue