forked from TrueCloudLab/frostfs-node
[#108] object/head: Return 404 error if header was not found
Define ErrNotFound error in headsvc package. Return ErrNotFound from Head method if the header was not found in the container. Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
parent
ae0dd9e051
commit
5ad0df7794
2 changed files with 3 additions and 1 deletions
|
@ -135,7 +135,7 @@ loop:
|
|||
}
|
||||
|
||||
if !h.traverser.Success() {
|
||||
return nil, errors.Errorf("(%T) incomplete object Head operation", h)
|
||||
return nil, errors.Wrapf(ErrNotFound, "(%T) incomplete object Head operation", h)
|
||||
}
|
||||
|
||||
return resp, nil
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue