fix type inference in scheduler

This commit is contained in:
Damien Elmes 2019-12-16 17:54:17 +10:00
parent 6f7c8915fe
commit d4145d1f04

View file

@ -311,7 +311,8 @@ order by due""" % self._deckLimit(),
# day learning first and card due? # day learning first and card due?
dayLearnFirst = self.col.conf.get("dayLearnFirst", False) dayLearnFirst = self.col.conf.get("dayLearnFirst", False)
c = dayLearnFirst and self._getLrnDayCard() if dayLearnFirst:
c = self._getLrnDayCard()
if c: if c:
return c return c
@ -321,7 +322,8 @@ order by due""" % self._deckLimit(),
return c return c
# day learning card due? # day learning card due?
c = not dayLearnFirst and self._getLrnDayCard() if not dayLearnFirst:
c = self._getLrnDayCard()
if c: if c:
return c return c