aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortomasz1986 <twilczynski@naver.com>2023-09-01 07:22:04 +0200
committerGitHub <noreply@github.com>2023-09-01 07:22:04 +0200
commit325b3b114fbbc4bc04c6a6672025f598286c3d65 (patch)
tree760422560183e946bcb0bfab473c07eed9063022
parent03590e5ac7ce1d541fbcc8d9ad48d08f52114e4c (diff)
downloadsyncthing-325b3b114fbbc4bc04c6a6672025f598286c3d65.tar.gz
syncthing-325b3b114fbbc4bc04c6a6672025f598286c3d65.zip
gui: Fix lastSeenDays error due to undefined deviceStats when adding new devices (ref #8730) (#9066)
-rwxr-xr-xgui/default/syncthing/core/syncthingController.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/gui/default/syncthing/core/syncthingController.js b/gui/default/syncthing/core/syncthingController.js
index 975cb4638..26e067a59 100755
--- a/gui/default/syncthing/core/syncthingController.js
+++ b/gui/default/syncthing/core/syncthingController.js
@@ -1090,7 +1090,7 @@ angular.module('syncthing.core')
}
// Disconnected
- if (!unused && $scope.deviceStats[deviceCfg.deviceID].lastSeenDays && $scope.deviceStats[deviceCfg.deviceID].lastSeenDays >= 7) {
+ if (!unused && $scope.deviceStats[deviceCfg.deviceID] && $scope.deviceStats[deviceCfg.deviceID].lastSeenDays && $scope.deviceStats[deviceCfg.deviceID].lastSeenDays >= 7) {
return status + 'disconnected-inactive';
} else {
return status + 'disconnected';