Skip to content

Commit

Permalink
Use may_load_at_height wrapper in cw4-stake
Browse files Browse the repository at this point in the history
  • Loading branch information
maurolacy committed Apr 19, 2021
1 parent 9bee38e commit dd1d40c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion contracts/cw4-stake/src/contract.rs
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,7 @@ pub fn query_staked(deps: Deps, addr: String) -> StdResult<StakedResponse> {
fn query_member(deps: Deps, addr: String, height: Option<u64>) -> StdResult<MemberResponse> {
let addr = deps.api.addr_validate(&addr)?;
let weight = match height {
Some(h) => members().primary.may_load_at_height(deps.storage, &addr, h),
Some(h) => members().may_load_at_height(deps.storage, &addr, h),
None => members().may_load(deps.storage, &addr),
}?;
Ok(MemberResponse { weight })
Expand Down

0 comments on commit dd1d40c

Please sign in to comment.