aboutsummaryrefslogtreecommitdiff
path: root/reachability/walk_expand_objects.go
diff options
context:
space:
mode:
Diffstat (limited to 'reachability/walk_expand_objects.go')
-rw-r--r--reachability/walk_expand_objects.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/reachability/walk_expand_objects.go b/reachability/walk_expand_objects.go
index 9dc2ff80..1f634c26 100644
--- a/reachability/walk_expand_objects.go
+++ b/reachability/walk_expand_objects.go
@@ -3,6 +3,7 @@ package reachability
import (
"fmt"
+ "codeberg.org/lindenii/furgit/errors"
"codeberg.org/lindenii/furgit/object"
"codeberg.org/lindenii/furgit/objecttype"
)
@@ -14,7 +15,7 @@ func (walk *Walk) expandObjects(item walkItem) ([]walkItem, error) {
}
if item.want != objecttype.TypeInvalid && ty != item.want {
- return nil, &ObjectTypeError{OID: item.id, Got: ty, Want: item.want}
+ return nil, &errors.ObjectTypeError{OID: item.id, Got: ty, Want: item.want}
}
switch ty {
@@ -76,7 +77,7 @@ func (walk *Walk) expandObjects(item walkItem) ([]walkItem, error) {
return []walkItem{{id: tag.Target, want: tag.TargetType}}, nil
case objecttype.TypeInvalid, objecttype.TypeFuture, objecttype.TypeOfsDelta, objecttype.TypeRefDelta:
- return nil, &ObjectTypeError{OID: item.id, Got: ty, Want: item.want}
+ return nil, &errors.ObjectTypeError{OID: item.id, Got: ty, Want: item.want}
}
return nil, fmt.Errorf("reachability: unreachable object type %d", ty)