We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2b11cf0 commit bc7b5a6Copy full SHA for bc7b5a6
packages/runtime/src/helpers/functionsMetaData.ts
@@ -35,7 +35,8 @@ export interface FunctionInfo {
35
export const writeFunctionConfiguration = async (functionInfo: FunctionInfo) => {
36
const { functionName, functionTitle, functionsDir } = functionInfo
37
const pluginPackagePath = '.netlify/plugins/package.json'
38
- const nodeModulesPath = join(resolveModuleRoot(NEXT_PLUGIN), 'package.json')
+ const moduleRoot = resolveModuleRoot(NEXT_PLUGIN)
39
+ const nodeModulesPath = moduleRoot ? join(moduleRoot, 'package.json') : null
40
41
const nextPluginVersion =
42
(await getNextRuntimeVersion(nodeModulesPath, true)) ||
0 commit comments