diff options
author | wxiaoguang <wxiaoguang@gmail.com> | 2023-05-09 15:34:36 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-09 15:34:36 +0800 |
commit | 023a048f52b5bf8c4b715285245a129f04e05a8c (patch) | |
tree | 2ea5c0d940a9439e9760b00f735d869444d87165 /modules/lfs | |
parent | c090f87a8db5b51e0aa9c7278b38ddc862c048ac (diff) | |
download | gitea-023a048f52b5bf8c4b715285245a129f04e05a8c.tar.gz gitea-023a048f52b5bf8c4b715285245a129f04e05a8c.zip |
Make repository response support HTTP range request (#24592)
Replace #20480
Replace #18448
Close #16414
Diffstat (limited to 'modules/lfs')
-rw-r--r-- | modules/lfs/content_store.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/modules/lfs/content_store.go b/modules/lfs/content_store.go index 53fac4ab85..daf8c6cfdd 100644 --- a/modules/lfs/content_store.go +++ b/modules/lfs/content_store.go @@ -18,9 +18,9 @@ import ( var ( // ErrHashMismatch occurs if the content has does not match OID - ErrHashMismatch = errors.New("Content hash does not match OID") + ErrHashMismatch = errors.New("content hash does not match OID") // ErrSizeMismatch occurs if the content size does not match - ErrSizeMismatch = errors.New("Content size does not match") + ErrSizeMismatch = errors.New("content size does not match") ) // ContentStore provides a simple file system based storage. @@ -105,7 +105,7 @@ func (s *ContentStore) Verify(pointer Pointer) (bool, error) { } // ReadMetaObject will read a git_model.LFSMetaObject and return a reader -func ReadMetaObject(pointer Pointer) (io.ReadCloser, error) { +func ReadMetaObject(pointer Pointer) (io.ReadSeekCloser, error) { contentStore := NewContentStore() return contentStore.Get(pointer) } |