[#226] pool/tree: Fix handling access denied error
(cherry picked from commit 6a52487edd
)
Signed-off-by: Denis Kirillov <d.kirillov@yadro.com>
Signed-off-by: Alex Vanin <a.vanin@yadro.com>
This commit is contained in:
parent
e5040d35e9
commit
8412b075a5
1 changed files with 1 additions and 1 deletions
|
@ -599,7 +599,7 @@ func handleError(msg string, err error) error {
|
|||
}
|
||||
if strings.Contains(err.Error(), "not found") {
|
||||
return fmt.Errorf("%w: %s", ErrNodeNotFound, err.Error())
|
||||
} else if strings.Contains(err.Error(), "is denied by") {
|
||||
} else if strings.Contains(err.Error(), "denied") {
|
||||
return fmt.Errorf("%w: %s", ErrNodeAccessDenied, err.Error())
|
||||
}
|
||||
return fmt.Errorf("%s: %w", msg, err)
|
||||
|
|
Loading…
Reference in a new issue