chore: remove unreachable functions

This commit is contained in:
2026-05-13 12:51:47 +02:00
parent c814e1d391
commit a99b8b3844
2 changed files with 1 additions and 36 deletions

View File

@@ -4,7 +4,6 @@ import (
"database/sql"
"fmt"
"os"
"path/filepath"
_ "github.com/mattn/go-sqlite3"
)
@@ -26,19 +25,3 @@ func GetDBFile() string {
return "mal.db"
}
// GetMigrationsDir returns the migrations directory, checking MIGRATIONS_DIR env var first
func GetMigrationsDir() (string, error) {
if dir := os.Getenv("MIGRATIONS_DIR"); dir != "" {
return dir, nil
}
wd, err := os.Getwd()
if err != nil {
return "", fmt.Errorf("failed to get working directory: %w", err)
}
return filepath.Join(wd, "migrations"), nil
}
// Init opens the database and returns a Queries instance
func Init(db *sql.DB) (*Queries, error) {
return New(db), nil
}