Fix construct_runtime multiple log issue (#2816)

* Fix comma issue

* multiple log test
This commit is contained in:
thiolliere
2019-06-07 15:27:55 +02:00
committed by Gavin Wood
parent d7ba5c00ba
commit 693ea3cb42
2 changed files with 7 additions and 4 deletions
@@ -163,14 +163,17 @@ mod module1 {
pub type Log<T, I> = RawLog<
T,
I,
<T as system::Trait>::Hash,
>;
/// A logs in this module.
#[cfg_attr(feature = "std", derive(serde::Serialize, Debug))]
#[derive(parity_codec::Encode, parity_codec::Decode, PartialEq, Eq, Clone)]
pub enum RawLog<T, I> {
pub enum RawLog<T, I, Hash> {
_Phantom(rstd::marker::PhantomData<(T, I)>),
AmountChange(u32),
ChangesTrieRoot(Hash),
AuthoritiesChange(Vec<()>),
}
pub const INHERENT_IDENTIFIER: InherentIdentifier = *b"12345678";
@@ -341,8 +344,8 @@ srml_support::construct_runtime!(
UncheckedExtrinsic = UncheckedExtrinsic
{
System: system::{Module, Call, Event, Log(ChangesTrieRoot)},
Module1_1: module1::<Instance1>::{Module, Call, Storage, Event<T, I>, Config<T, I>, Origin<T, I>, Log(), Inherent},
Module1_2: module1::<Instance2>::{Module, Call, Storage, Event<T, I>, Config<T, I>, Origin<T, I>, Log(), Inherent},
Module1_1: module1::<Instance1>::{Module, Call, Storage, Event<T, I>, Config<T, I>, Origin<T, I>, Log(ChangesTrieRoot, AuthoritiesChange), Inherent},
Module1_2: module1::<Instance2>::{Module, Call, Storage, Event<T, I>, Config<T, I>, Origin<T, I>, Log(ChangesTrieRoot, AuthoritiesChange), Inherent},
Module2: module2::{Module, Call, Storage, Event<T>, Config<T>, Origin<T>, Log(), Inherent},
Module2_1: module2::<Instance1>::{Module, Call, Storage, Event<T, I>, Config<T, I>, Origin<T, I>, Log(), Inherent},
Module2_2: module2::<Instance2>::{Module, Call, Storage, Event<T, I>, Config<T, I>, Origin<T, I>, Log(), Inherent},