mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-04 01:40:07 +00:00
remove warning infomation when use '*'
This commit is contained in:
parent
dee81ed56a
commit
d3d33aa834
@ -180,6 +180,10 @@ func (o *CanIOptions) RunAccessCheck() (bool, error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (o *CanIOptions) resourceFor(mapper meta.RESTMapper, resourceArg string) schema.GroupVersionResource {
|
func (o *CanIOptions) resourceFor(mapper meta.RESTMapper, resourceArg string) schema.GroupVersionResource {
|
||||||
|
if resourceArg == "*" {
|
||||||
|
return schema.GroupVersionResource{Resource: resourceArg}
|
||||||
|
}
|
||||||
|
|
||||||
fullySpecifiedGVR, groupResource := schema.ParseResourceArg(strings.ToLower(resourceArg))
|
fullySpecifiedGVR, groupResource := schema.ParseResourceArg(strings.ToLower(resourceArg))
|
||||||
gvr := schema.GroupVersionResource{}
|
gvr := schema.GroupVersionResource{}
|
||||||
if fullySpecifiedGVR != nil {
|
if fullySpecifiedGVR != nil {
|
||||||
|
Loading…
Reference in New Issue
Block a user