Skip to content

Commit

Permalink
Set pre-genesis flag before using it
Browse files Browse the repository at this point in the history
  • Loading branch information
paberr authored and jsdanielh committed Nov 23, 2024
1 parent ea10cda commit a304f86
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion lib/src/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,13 @@ impl ClientInner {
_ => true,
}
});

// Set pre-genesis flag.
#[cfg(feature = "database-storage")]
if config.storage.has_pre_genesis_database(config.network_id) {
provided_services |= Services::PRE_GENESIS_TRANSACTIONS;
}

let peer_contact = PeerContact::new(
peer_contact_addresses,
identity_keypair.public(),
Expand Down Expand Up @@ -353,7 +360,6 @@ impl ClientInner {
#[cfg(feature = "database-storage")]
let pre_genesis_environment = if config.storage.has_pre_genesis_database(config.network_id)
{
provided_services |= Services::PRE_GENESIS_TRANSACTIONS;
Some(
config
.storage
Expand Down

0 comments on commit a304f86

Please sign in to comment.