diff --git a/anki/sched.py b/anki/sched.py index 3469abbcb..d98240e19 100644 --- a/anki/sched.py +++ b/anki/sched.py @@ -650,6 +650,10 @@ did = ? and queue = 2 and due <= ? %s limit ?""" % order, # then the rest card.factor = max(1300, card.factor+[-150, 0, 150][ease-2]) card.due = self.today + card.ivl + if card.odid: + card.did = card.odid + card.odid = 0 + card.odue = 0 def _logRev(self, card, ease): def log(): diff --git a/tests/test_sched.py b/tests/test_sched.py index 398a2de48..37bf88f0a 100644 --- a/tests/test_sched.py +++ b/tests/test_sched.py @@ -531,6 +531,8 @@ def test_cram(): # should be able to answer it c = d.sched.getCard() d.sched.answerCard(c, 4) + # it should have been moved back to the original deck + assert c.did == 1 def test_adjIvl(): d = getEmptyDeck()