From 0d90ae26ac72fed2862bfaa59163b2cdfa5b20ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Colomb?= Date: Mon, 26 Oct 2020 09:09:32 +0100 Subject: [PATCH] gui: Fix undefined variables fallout from #7049 (#7056) --- gui/default/syncthing/core/syncthingController.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gui/default/syncthing/core/syncthingController.js b/gui/default/syncthing/core/syncthingController.js index efdfcc0be..fd5aa8b5c 100755 --- a/gui/default/syncthing/core/syncthingController.js +++ b/gui/default/syncthing/core/syncthingController.js @@ -1105,7 +1105,7 @@ angular.module('syncthing.core') }; $scope.setDevicePause = function (device, pause) { - $scope.devices[id].paused = pause; + $scope.devices[device].paused = pause; $scope.config.devices = $scope.deviceList(); $scope.saveConfig(); }; @@ -1466,6 +1466,7 @@ angular.module('syncthing.core') return; } + var id = $scope.currentDevice.deviceID delete $scope.devices[id]; $scope.config.devices = $scope.deviceList();