Skip to content

Commit 6c467cf

Browse files
aalejjoehan
andauthored
Correctly set FUNCTION_TARGET for multilevel grouped functions (#6423)
Co-authored-by: joehan <joehanley@google.com>
1 parent 6ff08fc commit 6c467cf

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
- Fixed an issue with deploying multilevel grouped functions containing v2 functions. (#6419)

src/gcp/cloudfunctionsv2.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,7 @@ export async function createFunction(cloudFunction: InputCloudFunction): Promise
331331

332332
cloudFunction.serviceConfig.environmentVariables = {
333333
...cloudFunction.serviceConfig.environmentVariables,
334-
FUNCTION_TARGET: functionId.replace("-", "."),
334+
FUNCTION_TARGET: functionId.replaceAll("-", "."),
335335
};
336336

337337
try {
@@ -439,7 +439,7 @@ export async function updateFunction(cloudFunction: InputCloudFunction): Promise
439439

440440
cloudFunction.serviceConfig.environmentVariables = {
441441
...cloudFunction.serviceConfig.environmentVariables,
442-
FUNCTION_TARGET: functionId.replace("-", "."),
442+
FUNCTION_TARGET: functionId.replaceAll("-", "."),
443443
};
444444

445445
try {

0 commit comments

Comments
 (0)