Skip to content

Commit 043c4e8

Browse files
author
Sean Newell
committed
Acutally commit change to fix broken test - need 5 characters for .d.ts extension
1 parent 8e3537d commit 043c4e8

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/services/models.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,8 +170,9 @@ export function getModels(arg: Array<typeof Model|string>): Array<typeof Model>
170170
const _models = fs
171171
.readdirSync(dir as string)
172172
.filter(file => {
173+
// TODO extension is not necessarily only the lasst three characters
173174
const extension = file.slice(-3);
174-
return extension === '.js' || (extension === '.ts' && file.slice(-4) !== '.d.ts');
175+
return extension === '.js' || (extension === '.ts' && file.slice(-5) !== '.d.ts');
175176
})
176177
.map(file => path.parse(file).name)
177178
.filter(uniqueFilter)

0 commit comments

Comments
 (0)