mirror of
https://github.com/ipfs/kubo.git
synced 2026-02-24 20:07:45 +08:00
cmds: use flushCopy instrad of copychunks
@mappum would this work?
This commit is contained in:
parent
ddd7540186
commit
322d6d0b05
@ -114,6 +114,9 @@ func (i Handler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
|
||||
_, isChan := res.Output().(chan interface{})
|
||||
streamChans, _, _ := req.Option("stream-channels").Bool()
|
||||
if isChan && streamChans {
|
||||
// w.WriteString(transferEncodingHeader + ": chunked\r\n")
|
||||
// w.Header().Set(channelHeader, "1")
|
||||
// w.WriteHeader(200)
|
||||
err = copyChunks(applicationJson, w, out)
|
||||
if err != nil {
|
||||
log.Error(err)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user