From b25960e60b7a7f022e86976d4d9a047b98b22c35 Mon Sep 17 00:00:00 2001 From: Kisel Jan Date: Thu, 6 Jun 2024 15:24:27 +0200 Subject: [PATCH] Fixed comment during refactoring (#6108) Also renamed variable as `r` looks too short and stands more for reader or ref rather than response/result. --- service/matching/tasklist/task_writer.go | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/service/matching/tasklist/task_writer.go b/service/matching/tasklist/task_writer.go index 1ec76135580..02914f6164a 100644 --- a/service/matching/tasklist/task_writer.go +++ b/service/matching/tasklist/task_writer.go @@ -226,7 +226,7 @@ writerLoop: maxReadLevel = taskIDs[i] } - r, err := w.db.CreateTasks(tasks) + resp, err := w.db.CreateTasks(tasks) err = w.handleErr(err) if err != nil { w.logger.Error("Persistent store operation failure", @@ -241,12 +241,11 @@ writerLoop: atomic.StoreInt64(&w.maxReadLevel, maxReadLevel) } - w.sendWriteResponse(reqs, err, r) + w.sendWriteResponse(reqs, err, resp) } case <-w.stopCh: // we don't close the appendCh here - // because that can cause on a send on closed - // channel panic on the appendTask() + // because that can cause "send on closed channel" panic on the appendTask() break writerLoop } }