mirror of
https://github.com/rancher/norman.git
synced 2025-09-06 01:30:20 +00:00
Don't check for object in collection actions
This commit is contained in:
@@ -222,8 +222,10 @@ func (s *Server) handle(rw http.ResponseWriter, req *http.Request) (*types.APICo
|
|||||||
}
|
}
|
||||||
|
|
||||||
func handleAction(action *types.Action, context *types.APIContext) error {
|
func handleAction(action *types.Action, context *types.APIContext) error {
|
||||||
if err := access.ByID(context, context.Version, context.Type, context.ID, nil); err != nil {
|
if context.ID != "" {
|
||||||
return err
|
if err := access.ByID(context, context.Version, context.Type, context.ID, nil); err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return context.Schema.ActionHandler(context.Action, action, context)
|
return context.Schema.ActionHandler(context.Action, action, context)
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user