diff options
author | Filip Navara <filip.navara@gmail.com> | 2019-04-23 13:16:56 +0200 |
---|---|---|
committer | Filip Navara <filip.navara@gmail.com> | 2019-04-23 13:16:56 +0200 |
commit | cbcb609afe98bf45df9c6c3b49553a46f4e93a63 (patch) | |
tree | d6d2bf8098fb3e8bbe091fde77b0edec73c6dd3c /plumbing | |
parent | 38c061e66678b4e6b92798796973b6f9335df10e (diff) | |
download | go-git-cbcb609afe98bf45df9c6c3b49553a46f4e93a63.tar.gz |
Address PR feedback
Signed-off-by: Filip Navara <filip.navara@gmail.com>
Diffstat (limited to 'plumbing')
-rw-r--r-- | plumbing/format/packfile/packfile.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/plumbing/format/packfile/packfile.go b/plumbing/format/packfile/packfile.go index 5f7a74b..895c152 100644 --- a/plumbing/format/packfile/packfile.go +++ b/plumbing/format/packfile/packfile.go @@ -184,7 +184,7 @@ func (p *Packfile) getObjectType(h *ObjectHeader) (typ plumbing.ObjectType, err } func (p *Packfile) objectAtOffset(offset int64, hash plumbing.Hash) (plumbing.EncodedObject, error) { - if obj, ok := p.deltaBaseCache.Get(hash); ok { + if obj, ok := p.cacheGet(hash); ok { return obj, nil } @@ -237,7 +237,7 @@ func (p *Packfile) getNextObject(h *ObjectHeader, hash plumbing.Hash) (plumbing. } else { err = p.fillOFSDeltaObjectContentWithBuffer(obj, h.OffsetReference, buf) } - return obj, nil + return obj, err } } else { size, err = p.getObjectSize(h) |