aboutsummaryrefslogtreecommitdiff
path: root/pkg/api/api0/serverlist.go
diff options
context:
space:
mode:
authorpg9182 <96569817+pg9182@users.noreply.github.com>2022-10-15 06:13:57 -0400
committerpg9182 <96569817+pg9182@users.noreply.github.com>2022-10-15 06:13:57 -0400
commitf93a8ef70cbb31c1ff4eb805dab9a21cb2d0a1bb (patch)
tree5d647b0cc6429dba542e56953bed9d4cca226a7e /pkg/api/api0/serverlist.go
parent28e3fbdfa2419f07d8a5c0beaa80d75c06856982 (diff)
downloadAtlas-f93a8ef70cbb31c1ff4eb805dab9a21cb2d0a1bb.tar.gz
Atlas-f93a8ef70cbb31c1ff4eb805dab9a21cb2d0a1bb.zip
pkg/api/api0: Force a /client/servers update when using ServerList.DeleteServerByID
Diffstat (limited to 'pkg/api/api0/serverlist.go')
-rw-r--r--pkg/api/api0/serverlist.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/pkg/api/api0/serverlist.go b/pkg/api/api0/serverlist.go
index 86d36c4..40e84c5 100644
--- a/pkg/api/api0/serverlist.go
+++ b/pkg/api/api0/serverlist.go
@@ -375,6 +375,10 @@ func (s *ServerList) DeleteServerByID(id string) bool {
s.mu.Lock()
defer s.mu.Unlock()
+ // force an update when we're finished
+ defer s.csForceUpdate()
+
+ // delete the server
var live bool
if s.servers2 != nil {
if esrv, exists := s.servers2[id]; exists {