Added support for DEBUG environment variable with image runner, make freeze use a similar method to speed

This commit is contained in:
TheEssem 2021-05-13 17:11:13 -05:00
parent e6b4db6e3e
commit 79bc36759c
No known key found for this signature in database
GPG key ID: A3F9F02129092FCA
3 changed files with 65 additions and 16 deletions

View file

@ -1,4 +1,4 @@
const magick = require("../build/Release/image.node");
const magick = require(`../build/${process.env.DEBUG && process.env.DEBUG === "true" ? "Debug" : "Release"}/image.node`);
const { isMainThread, parentPort, workerData } = require("worker_threads");
const fetch = require("node-fetch");