diff --git a/lee/state_machine/core/src/account.rs b/lee/state_machine/core/src/account.rs index e01fbd0ad..95b216f69 100644 --- a/lee/state_machine/core/src/account.rs +++ b/lee/state_machine/core/src/account.rs @@ -112,7 +112,7 @@ pub enum BalanceDiffError { pub struct AccountDiff { pub id: AccountId, pub diff_balance: BalanceDiff, - pub diff_data: Option>, + pub diff_data: Option, } /// Account to be used both in public and private contexts. diff --git a/lee/state_machine/core/src/program/mod.rs b/lee/state_machine/core/src/program/mod.rs index cc5571d69..137aeff7c 100644 --- a/lee/state_machine/core/src/program/mod.rs +++ b/lee/state_machine/core/src/program/mod.rs @@ -700,7 +700,7 @@ pub enum ProgramCall { Execute(ProgramInput, InstructionData), UpdateFromDiff { pre_state: Account, - diff_data: Vec, + diff_data: Data, }, } @@ -716,7 +716,7 @@ pub enum ProgramCall { #[derive(Serialize, Deserialize)] pub struct UpdateFromDiffOutput { pub pre_state: Account, - pub diff_data: Vec, + pub diff_data: Data, pub data: Data, } @@ -766,7 +766,7 @@ pub fn read_lee_call() -> ProgramCall { } CallKind::UpdateFromDiff => { let pre_state: Account = env::read(); - let diff_data: Vec = env::read(); + let diff_data: Data = env::read(); ProgramCall::UpdateFromDiff { pre_state, diff_data, @@ -906,10 +906,10 @@ fn validate_uniqueness_of_account_ids(pre_states: &[AccountWithMetadata]) -> boo } /// Commits an `update_from_diff` result to the journal, bound to the inputs that produced it. -pub fn write_update_from_diff_output(pre_state: &Account, diff_data: &[u8], data: &Data) { +pub fn write_update_from_diff_output(pre_state: &Account, diff_data: &Data, data: &Data) { env::commit(&UpdateFromDiffOutput { pre_state: pre_state.clone(), - diff_data: diff_data.to_vec(), + diff_data: diff_data.clone(), data: data.clone(), }); }