Allow Substrate Pallet to be Halted (#485)

* Copy-Pasta owner and freezing code from `message-lane`

* Halt pallet if bridge hasn't been initialized

* Make owner optional in `message-lane` pallet

* Add `is_halted` to `InitializationData`

* Fix initialization tests

* Only allow pallet to be initialized once

* Add some logging around halting and ownership changes

* Remove `target` in debugging calls
This commit is contained in:
Hernando Castano
2020-11-09 16:43:22 -05:00
committed by Bastian Köcher
parent 6c0110c11e
commit 3f7655a056
6 changed files with 223 additions and 52 deletions
@@ -158,6 +158,7 @@ fn testnet_genesis(
pallet_substrate_bridge: Some(BridgeRialtoConfig {
// We'll initialize the pallet with a dispatchable instead.
init_data: None,
owner: None,
}),
pallet_sudo: Some(SudoConfig { key: root_key }),
pallet_session: Some(SessionConfig {