gui: Avoid spurious comma in shared-with device list (fixes #8967) (#8970)

This commit is contained in:
Jakob Borg
2023-07-07 07:25:24 +02:00
committed by GitHub
parent 25ec2b63ab
commit 6ff5ed6d23
2 changed files with 7 additions and 4 deletions
@@ -1892,8 +1892,11 @@ angular.module('syncthing.core')
}
};
$scope.otherDevices = function () {
return $scope.deviceList().filter(function (n) {
$scope.otherDevices = function (devices) {
if (devices === undefined) {
devices = $scope.deviceList();
}
return devices.filter(function (n) {
return n.deviceID !== $scope.myID;
});
};