From 78f6bbbd0b8d251f72e16f6a61d294e069a4db80 Mon Sep 17 00:00:00 2001 From: Netlify Team Account 1 Date: Tue, 14 Dec 2021 17:41:13 +0100 Subject: [PATCH] fix: config-based schedule without esbuild --- src/lib/functions/runtimes/js/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/functions/runtimes/js/index.js b/src/lib/functions/runtimes/js/index.js index 2198c05225d..06b7be4d1c0 100644 --- a/src/lib/functions/runtimes/js/index.js +++ b/src/lib/functions/runtimes/js/index.js @@ -46,7 +46,7 @@ const getBuildFunction = async ({ config, directory, errorExit, func, projectRoo // main file otherwise. const functionDirectory = dirname(func.mainFile) const srcFiles = functionDirectory === directory ? [func.mainFile] : [functionDirectory] - const schedule = config[func.name]?.schedule + const schedule = config.functions[func.name]?.schedule return () => ({ schedule, srcFiles }) }