Skip to content

Commit db2b259

Browse files
authored
fix: exclude directories for local migrations (#4279)
1 parent 188a183 commit db2b259

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

pkg/migration/list.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ func ListLocalMigrations(migrationsDir string, fsys fs.FS, filter ...func(string
3838
var clean []string
3939
OUTER:
4040
for i, migration := range localMigrations {
41+
if migration.IsDir() {
42+
continue
43+
}
4144
filename := migration.Name()
4245
if i == 0 && shouldSkip(filename) {
4346
fmt.Fprintf(os.Stderr, "Skipping migration %s... (replace \"init\" with a different file name to apply this migration)\n", filename)

0 commit comments

Comments
 (0)