From a745af9d094fb4bcce1b47bb4d07e2158f90307c Mon Sep 17 00:00:00 2001 From: Vencislav Atanasov Date: Fri, 29 Mar 2024 11:48:52 +0200 Subject: [PATCH] Change sensor reading expiration to 2h --- src/widgets/SensorReading/SensorReading.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/widgets/SensorReading/SensorReading.jsx b/src/widgets/SensorReading/SensorReading.jsx index 613afdd..5944ed1 100644 --- a/src/widgets/SensorReading/SensorReading.jsx +++ b/src/widgets/SensorReading/SensorReading.jsx @@ -31,7 +31,7 @@ const SensorReading = ({ const unit = units[type]; const formattedValue = value.toFixed(unit[1]) + unit[0]; const readingAge = Date.now() - timestamp; - const isCurrent = readingAge <= 3_600_000; + const isCurrent = readingAge <= 7_200_000; const isVisible = readingAge <= 86_400_000; // TODO: only for type === Temperature const thermometerState = thresholds.filter(threshold => threshold < value).length;