Skip to content

Commit

Permalink
fix: Improve error message for invalid node type
Browse files Browse the repository at this point in the history
  • Loading branch information
Raphexion committed Nov 18, 2024
1 parent 2cb5444 commit c484340
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion node/router/messages/src/helpers/node_type.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ impl FromBytes for NodeType {
0 => Ok(Self::Client),
1 => Ok(Self::Prover),
2 => Ok(Self::Validator),
_ => Err(error("Invalid node type")),
x => Err(error(format!("Invalid node type. Expected either 0, 1 or 2. Got {x:?}"))),
}
}
}

0 comments on commit c484340

Please sign in to comment.