correct var names in live tail

This commit is contained in:
nityanandagohain 2022-07-19 16:38:28 +05:30
parent b5c8764605
commit 051f640100

View File

@ -1943,13 +1943,12 @@ func (aH *APIHandler) tailLogs(w http.ResponseWriter, r *http.Request) {
return
}
loop := true
for loop {
for {
select {
case ev := <-client.Logs:
case log := <-client.Logs:
var buf bytes.Buffer
enc := json.NewEncoder(&buf)
enc.Encode(ev)
enc.Encode(log)
fmt.Fprintf(w, "data: %v\n\n", buf.String())
flusher.Flush()
case <-client.Done: