You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openwhisk.apache.org by dg...@apache.org on 2021/04/01 00:03:19 UTC
[openwhisk-composer] branch master updated: Fixed bug when using
boolean value annotations with deploy (#70)
This is an automated email from the ASF dual-hosted git repository.
dgrove pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/openwhisk-composer.git
The following commit(s) were added to refs/heads/master by this push:
new d310c37 Fixed bug when using boolean value annotations with deploy (#70)
d310c37 is described below
commit d310c37df7bfadf3c6b086a428e44e24cb6028db
Author: Dylan Depass <dj...@gmail.com>
AuthorDate: Wed Mar 31 20:03:11 2021 -0400
Fixed bug when using boolean value annotations with deploy (#70)
---
bin/deploy.js | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/bin/deploy.js b/bin/deploy.js
index 5a54691..ccda9c7 100755
--- a/bin/deploy.js
+++ b/bin/deploy.js
@@ -73,7 +73,8 @@ try {
for (let annotation of [...(argv.annotation || [])]) {
const index = annotation.indexOf('=')
if (index < 0) throw Error('Annotation syntax must be "KEY=VALUE"')
- composition.annotations.push({ key: annotation.substring(0, index), value: annotation.substring(index + 1) })
+ const value = annotation.substring(index + 1).toLowerCase();
+ composition.annotations.push({ key: annotation.substring(0, index), value: (value === "true") ? true : value })
}
if (typeof argv['annotation-file'] === 'string') argv['annotation-file'] = [argv['annotation-file']]
for (let annotation of argv['annotation-file'] || []) {