Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: change check to disallow optimistic sends #3009

Merged
merged 9 commits into from
Jan 18, 2023
Merged
2 changes: 1 addition & 1 deletion modules/core/04-channel/keeper/packet.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ func (k Keeper) SendPacket(
return 0, sdkerrors.Wrap(types.ErrChannelNotFound, sourceChannel)
}

if channel.State == types.CLOSED {
if channel.State != types.OPEN {
crodriguezvega marked this conversation as resolved.
Show resolved Hide resolved
return 0, sdkerrors.Wrapf(
types.ErrInvalidChannelState,
"channel is CLOSED (got %s)", channel.State.String(),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we maybe change the error text to something like channel is not OPEN...?

Expand Down