diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index fabb4dfd87..9db71f86f4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -62,6 +62,10 @@ jobs: commitMessage: 'chore: publish changeset' username: 'devops' email: 'devops@dballerine.com' + # script to be used to publish the pr (changeset version by default) + versionScript: changeset version + # script to be used to publish the pr + publishScript: changeset publish env: GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} NPM_TOKEN: ${{ secrets.NPM_TOKEN }} diff --git a/packages/workflow-core/src/lib/plugins/external-plugin/api-plugin.ts b/packages/workflow-core/src/lib/plugins/external-plugin/api-plugin.ts index 168ebb8396..4839aee8f1 100644 --- a/packages/workflow-core/src/lib/plugins/external-plugin/api-plugin.ts +++ b/packages/workflow-core/src/lib/plugins/external-plugin/api-plugin.ts @@ -142,18 +142,11 @@ export class ApiPlugin { }; if (payload) { - const returnObj = { ...payload }; - const apiPluginInstance = this; - await Promise.all( - Object.keys(returnObj).map(async key => { - if (typeof returnObj[key] === 'string') { - returnObj[key] = await apiPluginInstance.replaceValuePlaceholders( - returnObj[key] as string, - returnObj, - ); - } - }), - ); + for (const key of Object.keys(payload)) { + if (typeof payload[key] === 'string') { + payload[key] = await this.replaceValuePlaceholders(payload[key] as string, payload); + } + } // @TODO: Use an enum over string literals for HTTP methods if (this.method.toUpperCase() !== 'GET') {