code: function applyToLapsedCardState(prev, ts, rating) {
    if (rating === 'easy' || rating.match(/^easy|good$/) && prev.consecutiveCorrect > 0) {
      return {
        master: prev.master,
        combination: prev.combination,
  
        mode: 'reviewing',
        factor: prev.factor,
        lapses: prev.lapses,
        interval: prev.consecutiveCorrect > 0 ? INITIAL_DAYS_WITHOUT_JUMP : INITIAL_DAYS_WITH_JUMP,
        lastReviewed: ts
      };
    }
    return {
      master: prev.master,
      combination: prev.combination,
  
      mode: 'lapsed',
      factor: prev.factor,
      lapses: prev.lapses,
      interval: prev.interval,
      lastReviewed: ts,
      consecutiveCorrect: rating === 'again' ? 0 : prev.consecutiveCorrect + 1
    };
  }
docs: -- applyToLapsedCardState(...)