Skip to content

Commit 39ffddb

Browse files
committed
Fix jq expression for handling AuthorAlreadyExists exception
1 parent be0e28d commit 39ffddb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

scripts/dmt/create_author.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,4 +20,4 @@ END
2020
)
2121

2222
woorl -s "damsel/proto/domain_config_v2.thrift" "http://dmt:8022/v1/domain/author" AuthorManagement Create "${AUTHOR_PARAMS}" |
23-
jq -r 'if has("already_exists") then .already_exists.id else .id end'
23+
jq -r 'if .exception == "AuthorAlreadyExists" then .data.id else .id end'

0 commit comments

Comments
 (0)