Addresses violation of: * clippy::derivable-impls. * clippy::useless-vec
@@ -149,7 +149,7 @@ pub fn guardian_set_update_allowed_in_shutdown() -> StdResult<()> {
.wrap()
.query_wasm_smart(wormhole_contract.clone(), &QueryMsg::GuardianSetInfo {})?;
- let new_guardian_keys = vec![
+ let new_guardian_keys = [
SigningKey::from_bytes(&[
93, 217, 189, 224, 168, 81, 157, 93, 238, 38, 143, 8, 182, 94, 69, 77, 232, 199, 238,
206, 15, 135, 221, 58, 43, 74, 0, 129, 54, 198, 62, 226,
@@ -5,10 +5,11 @@ use std::{fmt, str::FromStr};
use serde::{Deserialize, Deserializer, Serialize, Serializer};
use thiserror::Error;
-#[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)]
+#[derive(Debug, Default, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)]
pub enum Chain {
/// In the wormhole wire format, 0 indicates that a message is for any destination chain, it is
/// represented here as `Any`.
+ #[default]
Any,
/// Chains
@@ -291,12 +292,6 @@ impl FromStr for Chain {
}
-impl Default for Chain {
- fn default() -> Self {
- Self::Any
- }
-}
-
impl Serialize for Chain {
fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where