[FIX]comment should start with whitespace

Signed-off-by: Scaat Feng <scaat.feng@gmail.com>
pull/9066/head
Scaat Feng 4 years ago
parent 14f6bde04a
commit 1852694a65

@ -63,7 +63,7 @@ func NewLookupFunction(config *rest.Config) lookupFunc {
} }
return obj.UnstructuredContent(), nil return obj.UnstructuredContent(), nil
} }
//this will return a list // this will return a list
obj, err := client.List(context.Background(), metav1.ListOptions{}) obj, err := client.List(context.Background(), metav1.ListOptions{})
if err != nil { if err != nil {
if apierrors.IsNotFound(err) { if apierrors.IsNotFound(err) {
@ -112,7 +112,7 @@ func getAPIReourceForGVK(gvk schema.GroupVersionKind, config *rest.Config) (meta
return res, err return res, err
} }
for _, resource := range resList.APIResources { for _, resource := range resList.APIResources {
//if a resource contains a "/" it's referencing a subresource. we don't support suberesource for now. // if a resource contains a "/" it's referencing a subresource. we don't support suberesource for now.
if resource.Kind == gvk.Kind && !strings.Contains(resource.Name, "/") { if resource.Kind == gvk.Kind && !strings.Contains(resource.Name, "/") {
res = resource res = resource
res.Group = gvk.Group res.Group = gvk.Group

Loading…
Cancel
Save