forked from TrueCloudLab/frostfs-node
[#1428] node/acl: Make container ID as required param
Change pointer to value in request information since requests could not exist without container ID. Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
This commit is contained in:
parent
6cb9c13c5e
commit
d69eb2aaf3
5 changed files with 14 additions and 21 deletions
|
@ -19,8 +19,6 @@ type senderClassifier struct {
|
|||
netmap core.Source
|
||||
}
|
||||
|
||||
var errContainerIDNotSet = errors.New("container id is not set")
|
||||
|
||||
type classifyResult struct {
|
||||
role eaclSDK.Role
|
||||
isIR bool
|
||||
|
@ -29,12 +27,8 @@ type classifyResult struct {
|
|||
|
||||
func (c senderClassifier) classify(
|
||||
req MetaWithToken,
|
||||
idCnr *cidSDK.ID,
|
||||
idCnr cidSDK.ID,
|
||||
cnr *container.Container) (res *classifyResult, err error) {
|
||||
if idCnr == nil {
|
||||
return nil, errContainerIDNotSet
|
||||
}
|
||||
|
||||
ownerCnr := cnr.OwnerID()
|
||||
if ownerCnr == nil {
|
||||
return nil, errors.New("missing container owner")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue