gui: Readd check if device exists (ref #7059) (#7061)

This reverts commit c7d40ccbae.
This commit is contained in:
Simon Frei 2020-10-27 16:40:16 +01:00 committed by GitHub
parent c7d40ccbae
commit bc012d750d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1927,8 +1927,10 @@ angular.module('syncthing.core')
// Bump time
pendingFolder.time = (new Date()).toISOString();
$scope.devices[id].ignoredFolders.push(pendingFolder);
$scope.saveConfig();
if (id in $scope.devices) {
$scope.devices[id].ignoredFolders.push(pendingFolder);
$scope.saveConfig();
}
};
$scope.sharesFolder = function (folderCfg) {