Setting Upload-Offset directly to response
This commit is contained in:
parent
9ef0b54c7c
commit
ec4e47e3d9
|
@ -649,7 +649,7 @@ func (handler *UnroutedHandler) writeChunk(c *httpContext, resp HTTPResponse, up
|
||||||
|
|
||||||
// Send new offset to client
|
// Send new offset to client
|
||||||
newOffset := offset + bytesWritten
|
newOffset := offset + bytesWritten
|
||||||
resp.Headers["Upload-Offset"] = strconv.FormatInt(newOffset, 10)
|
c.res.Header().Set("Upload-Offset", strconv.FormatInt(newOffset, 10))
|
||||||
handler.Metrics.incBytesReceived(uint64(bytesWritten))
|
handler.Metrics.incBytesReceived(uint64(bytesWritten))
|
||||||
info.Offset = newOffset
|
info.Offset = newOffset
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue