Skip to content

Commit

Permalink
fix(WalletService): fixing HTTP 400 error when internal expected
Browse files Browse the repository at this point in the history
  • Loading branch information
geekbrother committed Oct 18, 2024
1 parent 6fbab8a commit bbdf5ae
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/handlers/wallet/handler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,13 @@ async fn handler_internal(
)))
.into_response(),
Err(e) => {
let is_internal = matches!(e, Error::Internal(_));
let is_internal = matches!(e, Error::Internal(_))
|| matches!(
e,
Error::SendPreparedCalls(SendPreparedCallsError::InternalError(_))
)
|| matches!(e, Error::PrepareCalls(PrepareCallsError::InternalError(_)));

if is_internal {
error!("Internal server error handling wallet RPC request: {e:?}");
}
Expand Down

0 comments on commit bbdf5ae

Please sign in to comment.