Fix change events

This commit is contained in:
Darren Shepherd 2020-02-25 21:24:00 -07:00
parent 1e5214b47e
commit e2e87cda53
2 changed files with 2 additions and 5 deletions

View File

@ -50,7 +50,7 @@ func NewFactory(cfg *rest.Config, impersonate bool) (*Factory, error) {
}
})
watchClientCfg := rest.CopyConfig(cfg)
watchClientCfg := rest.CopyConfig(clientCfg)
watchClientCfg.Timeout = 30 * time.Minute
md, err := metadata.NewForConfig(cfg)

View File

@ -71,11 +71,8 @@ func toAPI(schema *types.APISchema, obj runtime.Object) types.APIObject {
obj = moveToUnderscore(unstr)
}
gvr := attributes.GVR(schema)
t := fmt.Sprintf("%s/%s/%s", gvr.Group, gvr.Version, gvr.Resource)
apiObject := types.APIObject{
Type: t,
Type: schema.ID,
Object: obj,
}