Authoring with WASM runtime (#580)

This commit is contained in:
Arkadiy Paronyan
2018-08-17 10:40:40 +02:00
committed by Robert Habermeier
parent bde4152f1e
commit e482958705
3 changed files with 8 additions and 0 deletions
@@ -272,6 +272,14 @@ impl<T: Trait> Module<T> {
}
}
/// Lookup an address to get an Id, if there's one there.
pub fn lookup_address(a: address::Address<T::AccountId, T::AccountIndex>) -> Option<T::AccountId> {
match a {
address::Address::Id(i) => Some(i),
address::Address::Index(i) => Self::lookup_index(i),
}
}
// PUBLIC DISPATCH
/// Transfer some unlocked staking balance to another staker.