Various spelling fixes

This commit is contained in:
Michael Vines 2018-09-17 19:37:59 -07:00
parent aac1571670
commit aebf7f88e5
No known key found for this signature in database
GPG Key ID: 33F4FDEC4E0E88BD
3 changed files with 5 additions and 5 deletions

View File

@ -343,7 +343,7 @@ impl Bank {
/// Execute a transaction.
/// This method calls the contract's process_transaction method and verifies that the result of
/// the contract does not violate the bank's accounting rules.
/// The accounts are commited back to the bank only if this function returns Ok(_).
/// The accounts are committed back to the bank only if this function returns Ok(_).
fn execute_transaction(tx: Transaction, accounts: &mut [Account]) -> Result<Transaction> {
let pre_total: i64 = accounts.iter().map(|a| a.tokens).sum();
let pre_data: Vec<_> = accounts

View File

@ -127,7 +127,7 @@ impl BudgetContract {
}
if accounts[0].tokens < contract.tokens {
trace!("insufficent funds");
trace!("insufficient funds");
return Err(BudgetError::InsufficientFunds(tx.keys[0]));
} else {
accounts[0].tokens -= contract.tokens;
@ -175,7 +175,7 @@ impl BudgetContract {
Err(BudgetError::UninitializedContract(tx.keys[1]))
} else {
state.apply_timestamp(tx, accounts, *dt)?;
trace!("apply timestamp commited");
trace!("apply timestamp committed");
state.serialize(&mut accounts[1].userdata);
Ok(())
}
@ -191,7 +191,7 @@ impl BudgetContract {
} else {
trace!("apply signature");
state.apply_signature(tx, *signature, accounts)?;
trace!("apply signature commited");
trace!("apply signature committed");
state.serialize(&mut accounts[1].userdata);
Ok(())
}

View File

@ -53,7 +53,7 @@ pub struct Vote {
/// An instruction to progress the smart contract.
#[derive(Serialize, Deserialize, Debug, PartialEq, Eq, Clone)]
pub enum Instruction {
/// Declare and instanstansiate `Contract`.
/// Declare and instantiate `Contract`.
NewContract(Contract),
/// Tell a payment plan acknowledge the given `DateTime` has past.