We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent cda9d80 commit 2463460Copy full SHA for 2463460
bin/obfuscation-detector.js
@@ -1,8 +1,9 @@
1
#!/usr/bin/env node
2
import fs from 'node:fs';
3
-const detectObfuscation = require(__dirname + '/../src');
+import {fileURLToPath} from 'node:url';
4
+import {detectObfuscation} from './../src/index.js';
5
-if (require.main === module) {
6
+if (process.argv[1] === fileURLToPath(import.meta.url)) {
7
try {
8
const args = process.argv.slice(2);
9
if (args.length) {
0 commit comments