Skip to content

Commit

Permalink
Update client state
Browse files Browse the repository at this point in the history
  • Loading branch information
keppel committed Nov 16, 2024
1 parent 134dec7 commit 52a81fd
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions src/ibc/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,23 @@ impl Ibc {
let consensus_state = WrappedConsensusState {
inner: header.into(),
};

Check warning on line 233 in src/ibc/mod.rs

View check run for this annotation

Codecov / codecov/patch

src/ibc/mod.rs#L231-L233

Added lines #L231 - L233 were not covered by tests

let mut client_state = client
.client_state
.get(Default::default())?
.ok_or(Error::Ibc("Client not found".to_string()))?

Check warning on line 238 in src/ibc/mod.rs

View check run for this annotation

Codecov / codecov/patch

src/ibc/mod.rs#L235-L238

Added lines #L235 - L238 were not covered by tests
.inner
.inner()
.clone();

client_state.latest_height = height;
client.client_state.insert(
Default::default(),
WrappedClientState {
inner: client_state.into(),
},
)?;

Check warning on line 249 in src/ibc/mod.rs

View check run for this annotation

Codecov / codecov/patch

src/ibc/mod.rs#L240-L249

Added lines #L240 - L249 were not covered by tests

client
.consensus_states
.insert(height.into(), consensus_state)?;

Check warning on line 253 in src/ibc/mod.rs

View check run for this annotation

Codecov / codecov/patch

src/ibc/mod.rs#L251-L253

Added lines #L251 - L253 were not covered by tests
Expand Down

0 comments on commit 52a81fd

Please sign in to comment.