Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacob Vosmaer <jacob@gitlab.com>2019-03-29 14:29:23 +0300
committerJacob Vosmaer <jacob@gitlab.com>2019-03-29 14:29:23 +0300
commitc02b9ad129f348d080fc477172376400d58f19a8 (patch)
tree4a0ca4cf13a45cfb7491adde8e0eff1e4b71f486 /internal/helper/error.go
parentb88c19f98b575f1ac85df01b902b4d4e8dd9dc17 (diff)
UnlinkRepositoryFromObjectPool: stop removing objects/info/alternates
Diffstat (limited to 'internal/helper/error.go')
-rw-r--r--internal/helper/error.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/internal/helper/error.go b/internal/helper/error.go
index c20a1690a..81975315d 100644
--- a/internal/helper/error.go
+++ b/internal/helper/error.go
@@ -26,6 +26,9 @@ func ErrInvalidArgument(err error) error { return DecorateError(codes.InvalidArg
// ErrPreconditionFailed wraps error with codes.FailedPrecondition, unless err is already a grpc error
func ErrPreconditionFailed(err error) error { return DecorateError(codes.FailedPrecondition, err) }
+// ErrNotFound wraps error with codes.NotFound, unless err is already a grpc error
+func ErrNotFound(err error) error { return DecorateError(codes.NotFound, err) }
+
// GrpcCode emulates the old grpc.Code function: it translates errors into codes.Code values.
func GrpcCode(err error) codes.Code {
if err == nil {