Skip to content

Commit

Permalink
fix: change join to resolve in /api/v1/migrations
Browse files Browse the repository at this point in the history
  • Loading branch information
pportella23 authored Nov 21, 2024
1 parent 77d18b0 commit bead3b4
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 defaultMigrationOptions = {
dbClient: dbClient,
dryRun: true,
dir: join("infra", "migrations"),
dir: resolve("infra", "migrations"),
direction: "up",
verbose: true,
migrationsTable: "pgmigrations",
Expand Down

0 comments on commit bead3b4

Please sign in to comment.