From c6598a96518fa9a8de93c567c4ef8a44ad183e41 Mon Sep 17 00:00:00 2001 From: Alberto Gimeno Date: Sat, 14 Jan 2023 13:26:27 +0100 Subject: [PATCH] Fix FileMigrationProvider example (#276) --- src/migration/migrator.ts | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/migration/migrator.ts b/src/migration/migrator.ts index f01ff4bf2..885c6b4ef 100644 --- a/src/migration/migrator.ts +++ b/src/migration/migrator.ts @@ -32,12 +32,17 @@ export interface Migration { * other way. * * ```ts + * import { promises as fs } from 'fs' + * import path from 'path' + * * const migrator = new Migrator({ * db, - * provider: new FileMigrationProvider( + * provider: new FileMigrationProvider({ + * fs, + * path, * // Path to the folder that contains all your migrations. - * 'some/path/to/migrations' - * ) + * migrationFolder: 'some/path/to/migrations' + * }) * }) * ``` */