diff options
author | Paulo Gomes <pjbgf@linux.com> | 2023-07-02 14:42:34 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-07-02 14:42:34 +0100 |
commit | dd4e2b7f4b01e2aaafcf182d2884a186a6f37d21 (patch) | |
tree | 9eb4595171862dbbf92c88de57bc410bdbc7b12c /plumbing/transport | |
parent | 99ccca6bc543f88a18df50763d5fc13808e053e4 (diff) | |
parent | 025e1311f8473f65facf8cffeccc11e39466db4a (diff) | |
download | go-git-dd4e2b7f4b01e2aaafcf182d2884a186a6f37d21.tar.gz |
Merge pull request #792 from AriehSchneier/empty-fetch-with-shallows
plumbing: packp, A request is not empty if it contains shallows. Fixes #328
Diffstat (limited to 'plumbing/transport')
-rw-r--r-- | plumbing/transport/internal/common/common.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/plumbing/transport/internal/common/common.go b/plumbing/transport/internal/common/common.go index 99e0850..5fdf425 100644 --- a/plumbing/transport/internal/common/common.go +++ b/plumbing/transport/internal/common/common.go @@ -232,7 +232,7 @@ func (s *session) handleAdvRefDecodeError(err error) error { // UploadPack performs a request to the server to fetch a packfile. A reader is // returned with the packfile content. The reader must be closed after reading. func (s *session) UploadPack(ctx context.Context, req *packp.UploadPackRequest) (*packp.UploadPackResponse, error) { - if req.IsEmpty() && len(req.Shallows) == 0 { + if req.IsEmpty() { return nil, transport.ErrEmptyUploadPackRequest } |