From 16f9691e806a1468152d00902fa222932b451ef9 Mon Sep 17 00:00:00 2001 From: Adrien Raffin-Caboisse Date: Fri, 13 May 2022 11:20:40 +0200 Subject: [PATCH] fix: ignore emptyPolicy errors for db insertion --- machine.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/machine.go b/machine.go index 4ff723ce..caf1a59e 100644 --- a/machine.go +++ b/machine.go @@ -363,7 +363,7 @@ func (h *Headscale) UpdateMachine(machine *Machine) error { // SetTags takes a Machine struct pointer and update the forced tags. func (h *Headscale) SetTags(machine *Machine, tags []string) error { machine.ForcedTags = tags - if err := h.UpdateACLRules(); err != nil { + if err := h.UpdateACLRules(); !errors.Is(err, errEmptyPolicy) { return err } h.setLastStateChangeToNow(machine.Namespace.Name)