diff --git a/moleculer.config.ts b/moleculer.config.ts index 646534c..72eee40 100644 --- a/moleculer.config.ts +++ b/moleculer.config.ts @@ -76,7 +76,7 @@ const brokerConfig: BrokerOptions = { // More info: https://moleculer.services/docs/0.14/networking.html // Note: During the development, you don't need to define it because all services will be loaded locally. // In production you can set it via `TRANSPORTER=nats://localhost:4222` environment variable. - transporter: "NATS", // "NATS" + transporter: "redis", // "NATS" // Define a cacher. // More info: https://moleculer.services/docs/0.14/caching.html diff --git a/package-lock.json b/package-lock.json index 07f7c2d..c500f27 100644 --- a/package-lock.json +++ b/package-lock.json @@ -20,6 +20,7 @@ "dotenv": "^10.0.0", "fs-extra": "^10.0.0", "imghash": "^0.0.9", + "ioredis": "^4.28.1", "jsdom": "^15.2.1", "leven": "^3.1.0", "lodash": "^4.17.21", @@ -6333,9 +6334,9 @@ } }, "node_modules/ioredis": { - "version": "4.28.0", - "resolved": "https://registry.npmjs.org/ioredis/-/ioredis-4.28.0.tgz", - "integrity": "sha512-I+zkeeWp3XFgPT2CtJKxvaF5FjGBGt4yGYljRjQecdQKteThuAsKqffeF1lgHVlYnuNeozRbPOCDNZ7tDWPeig==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/ioredis/-/ioredis-4.28.1.tgz", + "integrity": "sha512-7gcrUJEcPHWy+eEyq6wIZpXtfHt8crhbc5+z0sqrnHUkwBblXinygfamj+/jx83Qo+2LW3q87Nj2VsuH6BF2BA==", "dependencies": { "cluster-key-slot": "^1.1.0", "debug": "^4.3.1", @@ -19492,9 +19493,9 @@ } }, "ioredis": { - "version": "4.28.0", - "resolved": "https://registry.npmjs.org/ioredis/-/ioredis-4.28.0.tgz", - "integrity": "sha512-I+zkeeWp3XFgPT2CtJKxvaF5FjGBGt4yGYljRjQecdQKteThuAsKqffeF1lgHVlYnuNeozRbPOCDNZ7tDWPeig==", + "version": "4.28.1", + "resolved": "https://registry.npmjs.org/ioredis/-/ioredis-4.28.1.tgz", + "integrity": "sha512-7gcrUJEcPHWy+eEyq6wIZpXtfHt8crhbc5+z0sqrnHUkwBblXinygfamj+/jx83Qo+2LW3q87Nj2VsuH6BF2BA==", "requires": { "cluster-key-slot": "^1.1.0", "debug": "^4.3.1", diff --git a/package.json b/package.json index 14da581..46e3b07 100644 --- a/package.json +++ b/package.json @@ -46,6 +46,7 @@ "dotenv": "^10.0.0", "fs-extra": "^10.0.0", "imghash": "^0.0.9", + "ioredis": "^4.28.1", "jsdom": "^15.2.1", "leven": "^3.1.0", "lodash": "^4.17.21", diff --git a/utils/uncompression.utils.ts b/utils/uncompression.utils.ts index 2c08289..90f6e41 100644 --- a/utils/uncompression.utils.ts +++ b/utils/uncompression.utils.ts @@ -88,8 +88,9 @@ export const extractCoverFromFile = async ( walkedFolder.name + "_cover.jpg" ); - const ebookMetaPath = - `${process.env.CALIBRE_EBOOK_META_PATH}` || `ebook-meta`; + const ebookMetaPath = process.env.CALIBRE_EBOOK_META_PATH + ? `${process.env.CALIBRE_EBOOK_META_PATH}` + : `ebook-meta`; result = await calibre.run( ebookMetaPath, [constructedPaths.inputFilePath],