mirror of
https://github.com/go-gitea/gitea.git
synced 2026-05-23 17:11:45 +02:00
fix typo
This commit is contained in:
parent
6e161a1d2e
commit
c2860491c2
@ -411,6 +411,10 @@ func serviceRPC(ctx *context.Context, h *serviceHandler, service string) {
|
||||
ctx.Resp.WriteHeader(http.StatusBadRequest)
|
||||
return
|
||||
}
|
||||
// git upload-archive does not have a "--stateless-rpc" option
|
||||
if service == ServiceTypeUploadPack || service == ServiceTypeReceivePack {
|
||||
cmd.AddArguments("--stateless-rpc")
|
||||
}
|
||||
|
||||
ctx.Resp.Header().Set("Content-Type", fmt.Sprintf("application/x-git-%s-result", service))
|
||||
|
||||
@ -434,10 +438,6 @@ func serviceRPC(ctx *context.Context, h *serviceHandler, service string) {
|
||||
}
|
||||
|
||||
var stderr bytes.Buffer
|
||||
// git upload-archive does not have a "--stateless-rpc" option
|
||||
if service == ServiceTypeUploadArchive || service == ServiceTypeReceivePack {
|
||||
cmd.AddArguments("--stateless-rpc")
|
||||
}
|
||||
if err := gitrepo.RunCmd(ctx, h.getStorageRepo(), cmd.AddArguments(".").
|
||||
WithEnv(append(os.Environ(), h.environ...)).
|
||||
WithStderr(&stderr).
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user