aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoris2023-02-05 11:20:04 +0100
committerJoris2023-02-05 11:20:04 +0100
commitae652a37ec2db6782565a9e843bc967e060d3906 (patch)
treecfb7b021ab30f749f44594c87f44f37af09288ad
parentf3377edd60c9427a87a658b724161407168a7efb (diff)
downloadflashcards-ae652a37ec2db6782565a9e843bc967e060d3906.tar.gz
flashcards-ae652a37ec2db6782565a9e843bc967e060d3906.tar.bz2
flashcards-ae652a37ec2db6782565a9e843bc967e060d3906.zip
Discard phonetics when checking response
-rwxr-xr-xbin/dev-server (renamed from bin/watch.sh)0
-rw-r--r--src/gui/question.rs1
2 files changed, 1 insertions, 0 deletions
diff --git a/bin/watch.sh b/bin/dev-server
index e3a6c28..e3a6c28 100755
--- a/bin/watch.sh
+++ b/bin/dev-server
diff --git a/src/gui/question.rs b/src/gui/question.rs
index 5055417..abb8fd7 100644
--- a/src/gui/question.rs
+++ b/src/gui/question.rs
@@ -216,6 +216,7 @@ fn is_correct(input: &str, responses: &[String]) -> bool {
responses
.iter()
.map(|r| r.split('(').collect::<Vec<&str>>()[0].trim())
+ .map(|r| r.split('[').collect::<Vec<&str>>()[0].trim())
.any(|x| x == input)
}