Skip to content

Commit 7f5dcf1

Browse files
fix(appconfig): stringify configurationVersion in block params
1 parent af48350 commit 7f5dcf1

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

apps/sim/blocks/blocks/appconfig.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -394,6 +394,7 @@ export const AppConfigBlock: BlockConfig<
394394
versionNumber,
395395
deploymentNumber,
396396
latestVersionNumber,
397+
configurationVersion,
397398
...rest
398399
} = params
399400

@@ -405,6 +406,12 @@ export const AppConfigBlock: BlockConfig<
405406
return Number.isNaN(parsed) ? undefined : parsed
406407
}
407408

409+
// Stringify: a versionNumber piped from an upstream step resolves to a JSON number,
410+
// but AppConfig's ConfigurationVersion (version number or label) must be a string.
411+
if (configurationVersion !== undefined && configurationVersion !== null) {
412+
result.configurationVersion = String(configurationVersion)
413+
}
414+
408415
const maxResultsInt = toInt(maxResults)
409416
if (maxResultsInt !== undefined) result.maxResults = maxResultsInt
410417

0 commit comments

Comments
 (0)