Skip to content

Commit 3d173cc

Browse files
committed
fix: throw if no debug
1 parent 896b569 commit 3d173cc

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/index.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,11 @@ function load() {
55
try {
66
return require('../build/Release/mongocrypt.node');
77
} catch {
8-
// eslint-disable-next-line no-console
9-
console.log('Could not load the native module mongocrypt.node');
8+
try {
9+
return require('../build/Debug/mongocrypt.node');
10+
} catch {
11+
throw new Error('Could not load the native module mongocrypt.node');
12+
}
1013
}
1114
}
1215

0 commit comments

Comments
 (0)