Skip to content

Commit

Permalink
remove extra condition
Browse files Browse the repository at this point in the history
  • Loading branch information
shueybubbles committed Apr 14, 2022
1 parent 5c716c9 commit 29bb0e8
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions token.go
Original file line number Diff line number Diff line change
Expand Up @@ -752,15 +752,14 @@ func processSingleResponse(ctx context.Context, sess *tdsSession, ch chan tokenS
}
ch <- done
if done.Status&doneCount != 0 {
if sess.logFlags&logRows != 0 && done.Status&doneCount != 0 {
if sess.logFlags&logRows != 0 {
sess.logger.Log(ctx, msdsn.LogRows, fmt.Sprintf("(%d row(s) affected)", done.RowCount))
}

if done.Status&doneCount != 0 {
if (colsReceived || done.CurCmd != cmdSelect) && outs.msgq != nil {
_ = sqlexp.ReturnMessageEnqueue(ctx, outs.msgq, sqlexp.MsgRowsAffected{Count: int64(done.RowCount)})
}
if (colsReceived || done.CurCmd != cmdSelect) && outs.msgq != nil {
_ = sqlexp.ReturnMessageEnqueue(ctx, outs.msgq, sqlexp.MsgRowsAffected{Count: int64(done.RowCount)})
}

}
colsReceived = false
if outs.msgq != nil {
Expand Down

0 comments on commit 29bb0e8

Please sign in to comment.