Skip to content

Commit 5f4c89b

Browse files
authored
[*] switch to compound assignment operators (#642)
1 parent 97b3d0b commit 5f4c89b

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

internal/pgengine/bootstrap.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ func (pge *PgEngine) getPgxConnConfig() *pgxpool.Config {
147147
connstr = fmt.Sprintf("host='%s' port='%d' dbname='%s' sslmode='%s' user='%s'",
148148
pge.Connection.Host, pge.Connection.Port, pge.Connection.DBName, pge.Connection.SSLMode, pge.Connection.User)
149149
if pge.Connection.Password != "" {
150-
connstr = connstr + fmt.Sprintf(" password='%s'", pge.Connection.Password)
150+
connstr += fmt.Sprintf(" password='%s'", pge.Connection.Password)
151151
}
152152
}
153153
connConfig, err := pgxpool.ParseConfig(connstr)

internal/scheduler/chain.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ func (sch *Scheduler) retrieveChainsAndRun(ctx context.Context, reboot bool) {
8787
var headChains []Chain
8888
msg := "Retrieve scheduled chains to run"
8989
if reboot {
90-
msg = msg + " @reboot"
90+
msg += " @reboot"
9191
}
9292
if reboot {
9393
err = sch.pgengine.SelectRebootChains(ctx, &headChains)

internal/scheduler/tasks.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ func (sch *Scheduler) executeBuiltinTask(ctx context.Context, name string, param
3838
if s, err = f(ctx, sch, val); err != nil {
3939
return
4040
}
41-
stdout = stdout + fmt.Sprintln(s)
41+
stdout += fmt.Sprintln(s)
4242
}
4343
return
4444
}

internal/tasks/files.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ func DownloadUrls(ctx context.Context, urls []string, dest string, workers int)
2929
if err = resp.Err(); err != nil {
3030
errstrings = append(errstrings, err.Error())
3131
} else {
32-
out = out + fmt.Sprintf("Downloaded %s to %s\n", resp.Request.URL(), resp.Filename)
32+
out += fmt.Sprintf("Downloaded %s to %s\n", resp.Request.URL(), resp.Filename)
3333
}
3434
}
3535
if len(errstrings) > 0 {

0 commit comments

Comments
 (0)