chore: upgrade go dependencies (#3657)
This commit is contained in:
@@ -6,8 +6,11 @@ import (
|
||||
"github.com/zeromicro/go-zero/core/lang"
|
||||
"github.com/zeromicro/go-zero/core/logx"
|
||||
v1 "k8s.io/api/core/v1"
|
||||
"k8s.io/client-go/tools/cache"
|
||||
)
|
||||
|
||||
var _ cache.ResourceEventHandler = (*EventHandler)(nil)
|
||||
|
||||
// EventHandler is ResourceEventHandler implementation.
|
||||
type EventHandler struct {
|
||||
update func([]string)
|
||||
@@ -24,7 +27,7 @@ func NewEventHandler(update func([]string)) *EventHandler {
|
||||
}
|
||||
|
||||
// OnAdd handles the endpoints add events.
|
||||
func (h *EventHandler) OnAdd(obj any) {
|
||||
func (h *EventHandler) OnAdd(obj any, _ bool) {
|
||||
endpoints, ok := obj.(*v1.Endpoints)
|
||||
if !ok {
|
||||
logx.Errorf("%v is not an object with type *v1.Endpoints", obj)
|
||||
|
||||
Reference in New Issue
Block a user