From 402921dac75f82a797ae1e80493c002411c5c2aa Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Wed, 10 Feb 2021 09:36:51 +1000 Subject: [PATCH] ignore manually scheduled cards in hour graph --- ts/graphs/hours.ts | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/ts/graphs/hours.ts b/ts/graphs/hours.ts index 858c17e1e..3c3e34542 100644 --- a/ts/graphs/hours.ts +++ b/ts/graphs/hours.ts @@ -46,8 +46,14 @@ function gatherData(data: pb.BackendProto.GraphsOut, range: GraphRange): Hour[] const cutoff = millisecondCutoffForRange(range, data.nextDayAtSecs); for (const review of data.revlog as pb.BackendProto.RevlogEntry[]) { - if (review.reviewKind == ReviewKind.EARLY_REVIEW) { - continue; + switch (review.reviewKind) { + case ReviewKind.LEARNING: + case ReviewKind.REVIEW: + case ReviewKind.RELEARNING: + break; // from switch + case ReviewKind.EARLY_REVIEW: + case ReviewKind.MANUAL: + continue; // next loop iteration } if (cutoff && (review.id as number) < cutoff) { continue;