MCPcopy Create free account
hub / github.com/ChainSafe/Delorean-Protocol / to_code

Function to_code

fendermint/app/src/tmconv.rs:331–337  ·  view source on GitHub ↗
(exit_code: ExitCode)

Source from the content-addressed store, hash-verified

329}
330
331pub fn to_code(exit_code: ExitCode) -> Code {
332 if exit_code.is_success() {
333 Code::Ok
334 } else {
335 Code::Err(NonZeroU32::try_from(exit_code.value()).expect("error codes are non-zero"))
336 }
337}
338
339pub fn to_error_msg(exit_code: ExitCode) -> &'static str {
340 match exit_code {

Callers 3

to_exec_tx_resultFunction · 0.85
to_check_txFunction · 0.85
to_queryFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected