shell icon indicating copy to clipboard operation
shell copied to clipboard

Error on preview composer.merge

Open epiresdasilva opened this issue 5 years ago • 2 comments

I'm getting an error when I try to preview my composer file on IBM Cloud Shell specifically when I use the merge function.

Example:

const composer = require('@ibm-functions/composer')

module.exports = composer.if(
        composer.sequence(
          composer.action('credit-card-online-debit-dev-findCreditCard'),
          params => { params.value = params.status === 'ACTIVE' }
        ),
        composer.if(
          composer.sequence(
              composer.merge(
                params => { params.debitValue},
                composer.action('credit-card-online-debit-dev-findBalance'),
              ),
              params => { params.value = params.balance - params.debitValue >= 0 }
          ),
          composer.action('credit-card-online-debit-dev-provisionalDebit'),
          params => { params.message = 'failure'}
        ),
        params => { params.message = 'failure' }
    )

Error: captura de tela 2018-10-25 as 20 10 12

epiresdasilva avatar Oct 25 '18 23:10 epiresdasilva

hi, thanks for the bug report. indeed, with the recent open sourcing of Composer, the Shell project is a bit out of date! bear with us, as we try to figure out the best approach to fixing this important issue.

starpit avatar Oct 25 '18 23:10 starpit

@starpit no problem, thank you too. Feel free to ask for more information if you need.

epiresdasilva avatar Oct 26 '18 00:10 epiresdasilva