Skip to content

Commit

Permalink
Derive default for MutableMetadataChanges
Browse files Browse the repository at this point in the history
  • Loading branch information
neekolas committed May 15, 2024
1 parent 2f80049 commit 48063c1
Showing 1 changed file with 1 addition and 13 deletions.
14 changes: 1 addition & 13 deletions xmtp_mls/src/groups/validated_commit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ impl CommitParticipant {
}
}

#[derive(Debug, Clone)]
#[derive(Debug, Clone, Default)]
pub struct MutableMetadataChanges {
pub metadata_field_changes: Vec<MetadataFieldChange>,
pub admins_added: Vec<Inbox>,
Expand All @@ -132,18 +132,6 @@ pub struct MutableMetadataChanges {
pub super_admins_removed: Vec<Inbox>,
}

impl Default for MutableMetadataChanges {
fn default() -> Self {
Self {
metadata_field_changes: vec![],
admins_added: vec![],
admins_removed: vec![],
super_admins_added: vec![],
super_admins_removed: vec![],
}
}
}

impl MutableMetadataChanges {
pub fn is_empty(&self) -> bool {
self.metadata_field_changes.is_empty()
Expand Down

0 comments on commit 48063c1

Please sign in to comment.