forked from TrueCloudLab/frostfs-s3-gw
[#657] Replace FileName with FilePath attribute
Signed-off-by: Denis Kirillov <denis@nspcc.ru>
This commit is contained in:
parent
c051d21420
commit
9cd4ef1ac4
13 changed files with 37 additions and 37 deletions
|
@ -675,7 +675,7 @@ func resInfoFromFilters(bucketName string, filters []eacl.Filter) resourceInfo {
|
|||
resInfo := resourceInfo{Bucket: bucketName}
|
||||
for _, filter := range filters {
|
||||
if filter.Matcher() == eacl.MatchStringEqual {
|
||||
if filter.Key() == object.AttributeFileName {
|
||||
if filter.Key() == object.AttributeFilePath {
|
||||
resInfo.Object = filter.Value()
|
||||
} else if filter.Key() == v2acl.FilterObjectID {
|
||||
resInfo.Version = filter.Value()
|
||||
|
@ -938,7 +938,7 @@ func formRecords(resource *astResource) ([]*eacl.Record, error) {
|
|||
}
|
||||
record.AddObjectIDFilter(eacl.MatchStringEqual, id)
|
||||
} else {
|
||||
record.AddObjectAttributeFilter(eacl.MatchStringEqual, object.AttributeFileName, resource.Object)
|
||||
record.AddObjectAttributeFilter(eacl.MatchStringEqual, object.AttributeFilePath, resource.Object)
|
||||
}
|
||||
}
|
||||
res = append(res, record)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue