From 7bd61a21b5cd23ffbdc343f87d81bb498a9bd7a0 Mon Sep 17 00:00:00 2001 From: Hein Date: Fri, 2 Oct 2026 23:31:41 +0200 Subject: [PATCH] fix: resolve gofumpt and staticcheck lint errors --- pkg/readers/typeorm/reader.go | 5 +++-- pkg/writers/pgsql/writer.go | 1 - 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/readers/typeorm/reader.go b/pkg/readers/typeorm/reader.go index 974ff43..9d85af2 100644 --- a/pkg/readers/typeorm/reader.go +++ b/pkg/readers/typeorm/reader.go @@ -901,9 +901,10 @@ func matchDecorator(line string) (string, bool) { for i := 0; i < len(rest); i++ { ch := rest[i] if quote != 0 { - if ch == '\\' { + switch ch { + case '\\': i++ - } else if ch == quote { + case quote: quote = 0 } continue diff --git a/pkg/writers/pgsql/writer.go b/pkg/writers/pgsql/writer.go index 4eb1e9b..a9d2ba6 100644 --- a/pkg/writers/pgsql/writer.go +++ b/pkg/writers/pgsql/writer.go @@ -2300,7 +2300,6 @@ func (w *Writer) executeStatements(statements []string, connString string) error // finishReport writes the optional report file and prints the execution summary. func (w *Writer) finishReport() error { - // Write report if path is specified if reportPath, ok := w.options.Metadata["report_path"].(string); ok && reportPath != "" { if err := w.writeReport(reportPath); err != nil {