diff --git a/Cargo.lock b/Cargo.lock index f40568e9..2a9ddd88 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -693,7 +693,7 @@ dependencies = [ [[package]] name = "seda-common" version = "0.0.0" -source = "git+https://github.com/sedaprotocol/seda-common-rs.git?branch=main#fe04866cbf4b3d673c7290e1fe43901292e2bbcd" +source = "git+https://github.com/sedaprotocol/seda-common-rs.git?branch=fix/u128-deser-errors#54a5e7737f2e123ca116db45bf10c37745d1b99d" dependencies = [ "base64 0.22.1", "cosmwasm-schema", diff --git a/Cargo.toml b/Cargo.toml index afe26952..226c8e2f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -34,7 +34,7 @@ k256 = { version = "0.13", default-features = false, features = ["ecdsa"] } libfuzzer-sys = "0.4" rand = "0.8" schemars = { version = "0.8", features = ["semver"] } -seda-common = { git = "https://github.com/sedaprotocol/seda-common-rs.git", branch = "main" } +seda-common = { git = "https://github.com/sedaprotocol/seda-common-rs.git", branch = "fix/u128-deser-errors" } # leaving this in to make local development easier # seda-common = { path = "../seda-common-rs" } semver = { version = "1.0", features = ["serde"] } diff --git a/contract/src/state.rs b/contract/src/state.rs index 24e3df35..4e4334f9 100644 --- a/contract/src/state.rs +++ b/contract/src/state.rs @@ -1,4 +1,4 @@ -use cosmwasm_std::{StdResult, Storage}; +use cosmwasm_std::{StdResult, Storage, Uint128}; use cw_storage_plus::{Item, Map}; use crate::types::PublicKey; @@ -17,8 +17,8 @@ pub fn get_seq(store: &dyn Storage, public_key: &PublicKey) -> StdResult { ACCOUNT_SEQ.may_load(store, public_key).map(|x| x.unwrap_or_default()) } -pub fn inc_get_seq(store: &mut dyn Storage, public_key: &PublicKey) -> StdResult { +pub fn inc_get_seq(store: &mut dyn Storage, public_key: &PublicKey) -> StdResult { let seq = ACCOUNT_SEQ.may_load(store, public_key)?.unwrap_or_default(); ACCOUNT_SEQ.save(store, public_key, &(seq + 1))?; - Ok(seq) + Ok(seq.into()) }