From ef4d9a42f8212a954703caba64c6a38f7db5a9fe Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Thu, 25 Jun 2009 06:46:05 +0900 Subject: [PATCH] only warn about a leech again after half the max fail rate --- ankiqt/ui/main.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ankiqt/ui/main.py b/ankiqt/ui/main.py index 556c9fb62..2127c34bc 100755 --- a/ankiqt/ui/main.py +++ b/ankiqt/ui/main.py @@ -453,8 +453,10 @@ Please do not file a bug report with Anki.
""") self.moveToState("getQuestion") def isLeech(self): + no = self.currentCard.noCount + max = self.deck.getInt('leechFails') return (not self.currentCard.successive and - self.currentCard.noCount >= self.deck.getInt('leechFails')) + no >= max and (max - no) % (max/2) == 0) def handleLeech(self): self.deck.refresh()