nimbella/netlify-plugin-nimbella

Refactor: use `failed` instead of `exitCode` to determine process failure

Closed this issue · 0 comments

In some cases a process can fail and still have an exitCode of 0
https://github.com/sindresorhus/execa#childprocessresult

You can use https://github.com/sindresorhus/execa#failed instead of exitCode to handle those cases here:

const {stdout, stderr, exitCode} = await run.command(command, {