diff --git a/anki/deck.py b/anki/deck.py index 6e18ba320..c16314d4a 100644 --- a/anki/deck.py +++ b/anki/deck.py @@ -1138,7 +1138,7 @@ select combinedDue from cards c where type = 1 order by combinedDue limit 1""")) earliestFail = self.s.scalar(self.cardLimit("revActive", "revInactive", """ -select combinedDue+%d from cards c where type = 0 and combinedDue > :lim +select combinedDue+%d from cards c where type = 0 order by combinedDue limit 1""" % self.delay0)) if earliestRev and earliestFail: