fix incorrect score setup

This commit is contained in:
2026-07-03 13:28:26 +03:00
parent 45ff877017
commit 15c3ec2018
6 changed files with 352 additions and 12 deletions
+3 -1
View File
@@ -79,7 +79,9 @@ impl CardStatistics {
self.score = MAX_SCORE
}
self.last_open = Utc::now();
}
updateCardStat(self.id, self.score, last_open).catch((err) =>
console.error('[Training] Ошибка сохранения last_opened:', err),
); }
pub fn calculated_score(&self) -> f32 {
let time = Utc::now() - self.last_open;