Skip to content

Commit

Permalink
fix: change join to resolve in /api/vi/migrations
Browse files Browse the repository at this point in the history
  • Loading branch information
AlAnNuB authored Sep 13, 2024
1 parent 516f08d commit ea3062d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pages/api/v1/migrations/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import migrationRunner from "node-pg-migrate";
import { join } from "node:path";
import { resolve } from "node:path";
import database from "infra/database.js";

export default async function migrations(request, response) {
Expand All @@ -18,7 +18,7 @@ export default async function migrations(request, response) {
const defaultMigrationOption = {
dbClient: dbClient,
dryRun: true,
dir: join("infra", "migrations"),
dir: resolve("infra", "migrations"),
direction: "up",
verbose: true,
migrationsTable: "pgmigrations",
Expand Down

0 comments on commit ea3062d

Please sign in to comment.