diff --git a/consul/client.go b/consul/client.go index 1a61841a7b..8089bb4621 100644 --- a/consul/client.go +++ b/consul/client.go @@ -224,9 +224,7 @@ func (c *Client) lanEventHandler() { switch e.EventType() { case serf.EventMemberJoin: c.nodeJoin(e.(serf.MemberEvent)) - case serf.EventMemberLeave: - fallthrough - case serf.EventMemberFailed: + case serf.EventMemberLeave, serf.EventMemberFailed: c.nodeFail(e.(serf.MemberEvent)) case serf.EventUser: c.localEvent(e.(serf.UserEvent)) diff --git a/consul/fsm.go b/consul/fsm.go index d12e81578c..7324a72bc3 100644 --- a/consul/fsm.go +++ b/consul/fsm.go @@ -230,9 +230,7 @@ func (c *consulFSM) applyACLOperation(buf []byte, index uint64) interface{} { } defer metrics.MeasureSince([]string{"consul", "fsm", "acl", string(req.Op)}, time.Now()) switch req.Op { - case structs.ACLForceSet: - fallthrough - case structs.ACLSet: + case structs.ACLForceSet, structs.ACLSet: if err := c.state.ACLSet(index, &req.ACL); err != nil { return err } else { diff --git a/consul/serf.go b/consul/serf.go index e18f15cc6e..ed80a74b0a 100644 --- a/consul/serf.go +++ b/consul/serf.go @@ -41,9 +41,7 @@ func (s *Server) lanEventHandler() { s.nodeJoin(e.(serf.MemberEvent), false) s.localMemberEvent(e.(serf.MemberEvent)) - case serf.EventMemberLeave: - fallthrough - case serf.EventMemberFailed: + case serf.EventMemberLeave, serf.EventMemberFailed: s.nodeFailed(e.(serf.MemberEvent), false) s.localMemberEvent(e.(serf.MemberEvent)) @@ -71,9 +69,7 @@ func (s *Server) wanEventHandler() { switch e.EventType() { case serf.EventMemberJoin: s.nodeJoin(e.(serf.MemberEvent), true) - case serf.EventMemberLeave: - fallthrough - case serf.EventMemberFailed: + case serf.EventMemberLeave, serf.EventMemberFailed: s.nodeFailed(e.(serf.MemberEvent), true) case serf.EventMemberUpdate: // Ignore case serf.EventMemberReap: // Ignore