optimize nested conditional (#709)

This commit is contained in:
Kevin Wan
2021-05-22 23:18:38 +08:00
committed by GitHub
parent 8998f16054
commit aaa3623404
2 changed files with 16 additions and 13 deletions

View File

@@ -53,9 +53,9 @@ func format(query string, args ...interface{}) (string, error) {
}
var b strings.Builder
argIndex := 0
var argIndex int
bytes := len(query)
for i := 0; i < bytes; i++ {
ch := query[i]
switch ch {