Skip to content

Commit

Permalink
fix errors
Browse files Browse the repository at this point in the history
  • Loading branch information
pkhry committed Oct 24, 2022
1 parent ae77771 commit 1fde5c2
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions crates/vm_library/src/outgoing.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,13 @@ pub struct SetOwned {
#[serde(serialize_with = "json_ser", deserialize_with = "json_deser")]
pub value: ContractType,
}

#[derive(Debug, Serialize)]
pub struct SetBorrowed<'a> {
pub key: &'a str,
#[serde(serialize_with = "json_ser")]
pub value: &'a Cow<'a, ContractType>,
}
fn json_ser<S>(t: &ContractType, serializer: S) -> Result<S::Ok, S::Error>
where
S: Serializer,
Expand Down

0 comments on commit 1fde5c2

Please sign in to comment.