diff options
Diffstat (limited to 'reachability')
| -rw-r--r-- | reachability/helpers.go | 6 | ||||
| -rw-r--r-- | reachability/reachability.go | 8 | ||||
| -rw-r--r-- | reachability/unit_test.go | 2 |
3 files changed, 8 insertions, 8 deletions
diff --git a/reachability/helpers.go b/reachability/helpers.go index 7a8c6b05..47fe313e 100644 --- a/reachability/helpers.go +++ b/reachability/helpers.go @@ -6,7 +6,7 @@ import ( giterrors "codeberg.org/lindenii/furgit/errors" objectid "codeberg.org/lindenii/furgit/object/id" - "codeberg.org/lindenii/furgit/object/store" + "codeberg.org/lindenii/furgit/object/storer" objecttype "codeberg.org/lindenii/furgit/object/type" ) @@ -39,7 +39,7 @@ func (walk *Walk) readHeaderType(id objectid.ObjectID) (objecttype.Type, error) func (r *Reachability) readHeaderType(id objectid.ObjectID) (objecttype.Type, error) { ty, _, err := r.store.ReadHeader(id) if err != nil { - if errors.Is(err, objectstore.ErrObjectNotFound) { + if errors.Is(err, objectstorer.ErrObjectNotFound) { return objecttype.TypeInvalid, &giterrors.ObjectMissingError{OID: id} } @@ -61,7 +61,7 @@ func (walk *Walk) readBytesContent(id objectid.ObjectID) ([]byte, error) { func (r *Reachability) readBytesContent(id objectid.ObjectID) ([]byte, error) { _, content, err := r.store.ReadBytesContent(id) if err != nil { - if errors.Is(err, objectstore.ErrObjectNotFound) { + if errors.Is(err, objectstorer.ErrObjectNotFound) { return nil, &giterrors.ObjectMissingError{OID: id} } diff --git a/reachability/reachability.go b/reachability/reachability.go index 127da2f4..54fc6e44 100644 --- a/reachability/reachability.go +++ b/reachability/reachability.go @@ -3,24 +3,24 @@ package reachability import ( commitgraphread "codeberg.org/lindenii/furgit/commitgraph/read" - "codeberg.org/lindenii/furgit/object/store" + "codeberg.org/lindenii/furgit/object/storer" ) // Reachability provides graph traversal over objects in one object store. // // It is not safe for concurrent use. type Reachability struct { - store objectstore.Store + store objectstorer.Store graph *commitgraphread.Reader } // New builds a Reachability over one object store. -func New(store objectstore.Store) *Reachability { +func New(store objectstorer.Store) *Reachability { return &Reachability{store: store} } // NewWithCommitGraph builds a Reachability over one object store with an // optional commit-graph reader for faster commit-domain traversal. -func NewWithCommitGraph(store objectstore.Store, graph *commitgraphread.Reader) *Reachability { +func NewWithCommitGraph(store objectstorer.Store, graph *commitgraphread.Reader) *Reachability { return &Reachability{store: store, graph: graph} } diff --git a/reachability/unit_test.go b/reachability/unit_test.go index 65568228..fad0280b 100644 --- a/reachability/unit_test.go +++ b/reachability/unit_test.go @@ -11,7 +11,7 @@ import ( "codeberg.org/lindenii/furgit/internal/testgit" "codeberg.org/lindenii/furgit/object" objectid "codeberg.org/lindenii/furgit/object/id" - "codeberg.org/lindenii/furgit/object/store/memory" + "codeberg.org/lindenii/furgit/object/storer/memory" objecttype "codeberg.org/lindenii/furgit/object/type" "codeberg.org/lindenii/furgit/reachability" ) |
