mirror of
https://github.com/rancher/norman.git
synced 2025-09-17 23:59:36 +00:00
Enable access control
This commit is contained in:
@@ -158,7 +158,7 @@ func newCollection(apiContext *types.APIContext) *types.GenericCollection {
|
||||
}
|
||||
|
||||
if apiContext.Method == http.MethodGet {
|
||||
if apiContext.AccessControl.CanCreate(apiContext.Schema) {
|
||||
if apiContext.AccessControl.CanCreate(apiContext, apiContext.Schema) {
|
||||
result.CreateTypes[apiContext.Schema.ID] = apiContext.URLBuilder.Collection(apiContext.Schema, apiContext.Version)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user