From 967e111a663c18b5f4a87f3ae38d076f3ab6c200 Mon Sep 17 00:00:00 2001 From: Eugene Burkov Date: Wed, 2 Dec 2020 13:52:17 +0300 Subject: [PATCH] all: improve code quality --- internal/dhcpd/dhcpd.go | 5 ----- internal/util/network_utils.go | 5 +---- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/internal/dhcpd/dhcpd.go b/internal/dhcpd/dhcpd.go index 999e9c7abbb..be44aeb932c 100644 --- a/internal/dhcpd/dhcpd.go +++ b/internal/dhcpd/dhcpd.go @@ -79,11 +79,6 @@ type ServerInterface interface { SetOnLeaseChanged(onLeaseChanged OnLeaseChangedT) } -// CheckConfig checks the configuration -func (s *Server) CheckConfig(config ServerConfig) error { - return nil -} - // Create - create object func Create(config ServerConfig) *Server { s := &Server{} diff --git a/internal/util/network_utils.go b/internal/util/network_utils.go index 3aafecfff36..1731ed08c93 100644 --- a/internal/util/network_utils.go +++ b/internal/util/network_utils.go @@ -33,10 +33,7 @@ func GetValidNetInterfaces() ([]net.Interface, error) { netIfaces := []net.Interface{} - for i := range ifaces { - iface := ifaces[i] - netIfaces = append(netIfaces, iface) - } + netIfaces = append(netIfaces, ifaces...) return netIfaces, nil }