diff --git a/.changelog/unreleased/bug-fixes/863-immut-ref-in-validate.md b/.changelog/unreleased/bug-fixes/863-immut-ref-in-validate.md new file mode 100644 index 000000000..91cbda02b --- /dev/null +++ b/.changelog/unreleased/bug-fixes/863-immut-ref-in-validate.md @@ -0,0 +1,2 @@ +- Replace mutable ref with immutable ref in validate handler + ([\#863](https://github.com/cosmos/ibc-rs/issues/863)) \ No newline at end of file diff --git a/crates/ibc/src/core/handler.rs b/crates/ibc/src/core/handler.rs index 5ddebcf97..7c2babfe3 100644 --- a/crates/ibc/src/core/handler.rs +++ b/crates/ibc/src/core/handler.rs @@ -51,11 +51,7 @@ pub fn dispatch( /// That is, the state transition of message `i` must be applied before /// message `i+1` is validated. This is equivalent to calling /// `dispatch()` on each successively. -pub fn validate( - ctx: &Ctx, - router: &mut impl Router, - msg: MsgEnvelope, -) -> Result<(), RouterError> +pub fn validate(ctx: &Ctx, router: &impl Router, msg: MsgEnvelope) -> Result<(), RouterError> where Ctx: ValidationContext, {