From 79b9aaab8101f182a8d1cdf39e883df6c2ffbcf7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sven=20Bl=C3=BCge?= Date: Mon, 10 Feb 2025 14:14:25 +0100 Subject: [PATCH 1/2] Rename variable for consistency in helper handling because supportedHelpers is no longer available. --- lib/plugin/autoDelay.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/plugin/autoDelay.js b/lib/plugin/autoDelay.js index ccd4a7836..d8df375db 100644 --- a/lib/plugin/autoDelay.js +++ b/lib/plugin/autoDelay.js @@ -52,13 +52,13 @@ const defaultConfig = { * */ module.exports = function (config) { - supportedHelpers.push('REST') + standardActingHelpers.push('REST') const helpers = Container.helpers() let helper config = Object.assign(defaultConfig, config) - for (const helperName of supportedHelpers) { + for (const helperName of standardActingHelpers) { if (Object.keys(helpers).indexOf(helperName) > -1) { helper = helpers[helperName] } From b7ed173c5e0e7652df69947fb08fd957be146a54 Mon Sep 17 00:00:00 2001 From: Michael Bodnarchuk Date: Mon, 10 Feb 2025 23:55:41 +0000 Subject: [PATCH 2/2] Apply suggestions from code review --- lib/plugin/autoDelay.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/plugin/autoDelay.js b/lib/plugin/autoDelay.js index d8df375db..cdc046f8d 100644 --- a/lib/plugin/autoDelay.js +++ b/lib/plugin/autoDelay.js @@ -52,13 +52,13 @@ const defaultConfig = { * */ module.exports = function (config) { - standardActingHelpers.push('REST') + const affectedHelpers = [...standardActingHelpers, 'REST'] const helpers = Container.helpers() let helper config = Object.assign(defaultConfig, config) - for (const helperName of standardActingHelpers) { + for (const helperName of affectedHelpers) { if (Object.keys(helpers).indexOf(helperName) > -1) { helper = helpers[helperName] }