16
16
// along with Polkadot. If not, see <http://www.gnu.org/licenses/>.
17
17
18
18
use crate :: {
19
- relay_chain_specs:: { PaseoChainSpec } ,
19
+ relay_chain_specs:: PaseoChainSpec ,
20
20
system_parachains_specs:: {
21
- AssetHubPaseoChainSpec ,
22
- BridgeHubPaseoChainSpec , CoretimePaseoChainSpec , PeoplePaseoChainSpec ,
21
+ AssetHubPaseoChainSpec , BridgeHubPaseoChainSpec , CoretimePaseoChainSpec ,
22
+ PeoplePaseoChainSpec ,
23
23
} ,
24
24
ChainSpec ,
25
25
} ;
@@ -36,16 +36,21 @@ pub fn from_json_file(filepath: &str, supported: String) -> Result<Box<dyn Chain
36
36
let chain_spec: EmptyChainSpecWithId = serde_json:: from_reader ( reader)
37
37
. expect ( "Failed to read 'json' file with ChainSpec configuration" ) ;
38
38
match & chain_spec. id {
39
- x if x. eq ( "paseo" ) | x. eq ( "paseo-local" ) | x. eq ( "paseo-dev" ) =>
40
- Ok ( Box :: new ( PaseoChainSpec :: from_json_file ( path) ?) ) ,
41
- x if x. starts_with ( "asset-hub-paseo" ) =>
42
- Ok ( Box :: new ( AssetHubPaseoChainSpec :: from_json_file ( path) ?) ) ,
43
- x if x. starts_with ( "paseo-bridge-hub" ) =>
44
- Ok ( Box :: new ( BridgeHubPaseoChainSpec :: from_json_file ( path) ?) ) ,
45
- x if x. starts_with ( "paseo-coretime" ) =>
46
- Ok ( Box :: new ( CoretimePaseoChainSpec :: from_json_file ( path) ?) ) ,
47
- x if x. starts_with ( "paseo-people" ) =>
48
- Ok ( Box :: new ( PeoplePaseoChainSpec :: from_json_file ( path) ?) ) ,
39
+ x if x. eq ( "paseo" ) | x. eq ( "paseo-local" ) | x. eq ( "paseo-dev" ) => {
40
+ Ok ( Box :: new ( PaseoChainSpec :: from_json_file ( path) ?) )
41
+ } ,
42
+ x if x. starts_with ( "asset-hub-paseo" ) => {
43
+ Ok ( Box :: new ( AssetHubPaseoChainSpec :: from_json_file ( path) ?) )
44
+ } ,
45
+ x if x. starts_with ( "paseo-bridge-hub" ) => {
46
+ Ok ( Box :: new ( BridgeHubPaseoChainSpec :: from_json_file ( path) ?) )
47
+ } ,
48
+ x if x. starts_with ( "paseo-coretime" ) => {
49
+ Ok ( Box :: new ( CoretimePaseoChainSpec :: from_json_file ( path) ?) )
50
+ } ,
51
+ x if x. starts_with ( "paseo-people" ) => {
52
+ Ok ( Box :: new ( PeoplePaseoChainSpec :: from_json_file ( path) ?) )
53
+ } ,
49
54
_ => Err ( format ! ( "Unknown chain 'id' in json file. Only supported: {supported}'" ) ) ,
50
55
}
51
56
}
0 commit comments