From a3b4007dbfbcbab32017c4cacae4df81fbc8569d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ma=C3=ABl=20Nison?= Date: Sat, 31 Aug 2019 16:10:43 +0200 Subject: [PATCH] Uses require.resolve --- lib/loaders/pitcher.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/loaders/pitcher.js b/lib/loaders/pitcher.js index 5cb3f46e2..222b9130c 100644 --- a/lib/loaders/pitcher.js +++ b/lib/loaders/pitcher.js @@ -128,7 +128,7 @@ module.exports.pitch = function (remainingRequest) { if (query.type === `template`) { const path = require('path') const cacheLoader = cacheDirectory && cacheIdentifier - ? [`cache-loader?${JSON.stringify({ + ? [`${require.resolve('cache-loader')}?${JSON.stringify({ // For some reason, webpack fails to generate consistent hash if we // use absolute paths here, even though the path is only used in a // comment. For now we have to ensure cacheDirectory is a relative path.