Skip to content

Commit

Permalink
Merge pull request #125 from willkrakow/bugfix/require-resolve
Browse files Browse the repository at this point in the history
Fix use of CommonJS require.resolve
  • Loading branch information
giga-a authored Jan 21, 2024
2 parents 5f26863 + fea3134 commit 04a5b65
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion modules/slow-scan.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,12 @@ import extraction from './extraction.js'
import async from 'async'
import sanitizeHtml from 'sanitize-html'
import firefox from 'selenium-webdriver/firefox.js'
import {Builder,By,Key} from 'selenium-webdriver'
import {Builder,By} from 'selenium-webdriver'
import path from 'path'
import engine from './engine.js'
import {createRequire} from 'node:module';

const require = createRequire(import.meta.url);

if (process.platform === 'win32') {
const package_path = path.join(path.dirname(require.resolve('geckodriver')), '..')
Expand Down

0 comments on commit 04a5b65

Please sign in to comment.