CQ fixes
Build and Push Docker Image / build-and-push (pull_request) Successful in 1m0s
Python Code Quality / python-code-quality (pull_request) Successful in 10s
Python Test / python-test (pull_request) Successful in 19s

This commit is contained in:
Brian Bjarke Jensen
2025-12-03 21:29:36 +01:00
parent 93eb1dc458
commit 63fc4b618c
+6 -4
View File
@@ -410,7 +410,9 @@
const prevEnd = entry.end_time || entry.start_time;
const sessionStartDate = new Date(sessionStart);
const prevEndDate = new Date(prevEnd);
const diffMins = Math.abs((sessionStartDate - prevEndDate) / 60000);
const diffMins = Math.abs(
(sessionStartDate - prevEndDate) / 60000,
);
if (diffMins > 30) {
break;
}
@@ -421,7 +423,7 @@
// Calculate accumulated feeding time for all events in the session
let accumulatedMinutes = 0;
sessionEntries.forEach(entry => {
sessionEntries.forEach((entry) => {
if (entry.end_time && entry.start_time) {
const start = new Date(entry.start_time);
const end = new Date(entry.end_time);
@@ -434,14 +436,14 @@
// Build a string showing all feeding types used during the session
const feedingTypesSet = new Set();
sessionEntries.forEach(entry => {
sessionEntries.forEach((entry) => {
if (entry.feeding_type) {
feedingTypesSet.add(entry.feeding_type);
}
});
const feedingTypesString = Array.from(feedingTypesSet)
.map(formatFeedingType)
.join(', ');
.join(", ");
// Compose a session object
lastFeeding = {