Commit f652333
committed
fix(kit): use path.basename/dirname in embeddedMigrations to fix Windows path separators
On Windows, snapshot paths use backslash separators. The previous
entry.split('/')[...length - 2] approach returns undefined when the
path contains only backslashes, causing migrations.js to import from
'./undefined/migration.sql'.
Replace with path.basename(path.dirname(entry)) which correctly
extracts the parent folder name on all platforms.1 parent 7eb39f0 commit f652333
1 file changed
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
97 | 97 | | |
98 | 98 | | |
99 | 99 | | |
100 | | - | |
| 100 | + | |
101 | 101 | | |
102 | 102 | | |
103 | 103 | | |
| |||
0 commit comments