mirror of
https://github.com/kyverno/kyverno.git
synced 2025-03-31 03:45:17 +00:00
fix 843 (#844)
This commit is contained in:
parent
ffe9fbd05b
commit
6f039147c8
1 changed files with 2 additions and 3 deletions
|
@ -52,7 +52,7 @@ func NewClient(config *rest.Config, resync time.Duration, stopCh <-chan struct{}
|
|||
client: dclient,
|
||||
clientConfig: config,
|
||||
kclient: kclient,
|
||||
log: log.WithName("Client"),
|
||||
log: log.WithName("dclient"),
|
||||
}
|
||||
// Set discovery client
|
||||
discoveryClient := ServerPreferredResources{cachedClient: memory.NewMemCacheClient(kclient.Discovery()), log: client.log}
|
||||
|
@ -292,8 +292,7 @@ func loadServerResources(k string, cdi discovery.CachedDiscoveryInterface, log l
|
|||
emptyGVR := schema.GroupVersionResource{}
|
||||
serverresources, err := cdi.ServerPreferredResources()
|
||||
if err != nil {
|
||||
logger.Error(err, "failed to get registered preferred resources")
|
||||
return emptyGVR, err
|
||||
logger.V(4).Info("failed to get registered preferred resources", "err", err.Error())
|
||||
}
|
||||
for _, serverresource := range serverresources {
|
||||
for _, resource := range serverresource.APIResources {
|
||||
|
|
Loading…
Add table
Reference in a new issue