fix: resolve noinlineerr lint issues

This commit is contained in:
user
2026-02-20 03:17:09 -08:00
parent f125a3f591
commit 3d968a1102
3 changed files with 28 additions and 11 deletions

View File

@@ -553,7 +553,8 @@ func (s *Database) connect(ctx context.Context) error {
s.log.Info("database connected")
// Item 9: Enable foreign keys on every connection
if _, err := s.db.ExecContext(ctx, "PRAGMA foreign_keys = ON"); err != nil {
_, err = s.db.ExecContext(ctx, "PRAGMA foreign_keys = ON")
if err != nil {
return fmt.Errorf("enable foreign keys: %w", err)
}
@@ -709,7 +710,8 @@ func (s *Database) applyMigrations(
)
}
if err := tx.Commit(); err != nil {
err = tx.Commit()
if err != nil {
return fmt.Errorf(
"commit migration %d: %w", m.version, err,
)