Skip to content

Commit

Permalink
fix: don't show stacktrace for ACI-not-match error
Browse files Browse the repository at this point in the history
  • Loading branch information
davidyuk committed Apr 22, 2024
1 parent b422456 commit b1b53b5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/aecli.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env node
import { RestError } from '@azure/core-rest-pipeline';
import { InvalidPasswordError, NodeInvocationError } from '@aeternity/aepp-sdk';
import { InvalidPasswordError, NodeInvocationError, ContractError } from '@aeternity/aepp-sdk';
import { setCommandOptions } from './utils/config.js';
import { prepareOptions } from './utils/default-option-description.js';
import CliError from './utils/CliError.js';
Expand All @@ -16,6 +16,7 @@ try {
|| error instanceof RestError
|| error instanceof InvalidPasswordError
|| error instanceof NodeInvocationError
|| (error instanceof ContractError && error.message.includes('ACI doesn\'t match called contract'))
|| error.code === 'ENOENT'
) program.error(error.message);
else throw error;
Expand Down

0 comments on commit b1b53b5

Please sign in to comment.