Skip to content

Commit

Permalink
chore: client state key nit (#3226)
Browse files Browse the repository at this point in the history
  • Loading branch information
crodriguezvega committed Mar 2, 2023
1 parent 46e1a42 commit 0ec6aad
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docs/ibc/light-clients/localhost/client-state.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ func (cs ClientState) UpdateState(ctx sdk.Context, cdc codec.BinaryCodec, client
height := clienttypes.GetSelfHeight(ctx)
cs.LatestHeight = height

clientStore.Set([]byte(host.KeyClientState), clienttypes.MustMarshalClientState(cdc, &cs))
clientStore.Set(host.ClientStateKey(), clienttypes.MustMarshalClientState(cdc, &cs))

return []exported.Height{height}
}
Expand Down
4 changes: 2 additions & 2 deletions modules/light-clients/09-localhost/client_state.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ func (cs ClientState) Initialize(ctx sdk.Context, cdc codec.BinaryCodec, clientS
LatestHeight: clienttypes.GetSelfHeight(ctx),
}

clientStore.Set([]byte(host.KeyClientState), clienttypes.MustMarshalClientState(cdc, &clientState))
clientStore.Set(host.ClientStateKey(), clienttypes.MustMarshalClientState(cdc, &clientState))

return nil
}
Expand Down Expand Up @@ -169,7 +169,7 @@ func (cs ClientState) UpdateState(ctx sdk.Context, cdc codec.BinaryCodec, client
height := clienttypes.GetSelfHeight(ctx)
cs.LatestHeight = height

clientStore.Set([]byte(host.KeyClientState), clienttypes.MustMarshalClientState(cdc, &cs))
clientStore.Set(host.ClientStateKey(), clienttypes.MustMarshalClientState(cdc, &cs))

return []exported.Height{height}
}
Expand Down

0 comments on commit 0ec6aad

Please sign in to comment.