chore: Fix new clippy warnings
This commit is contained in:
parent
68eecf71af
commit
2bdbf49535
@ -133,7 +133,7 @@ impl ImageMessageEventContent {
|
||||
#[cfg(feature = "unstable-msc3552")]
|
||||
file: Some(FileContent::encrypted(file.url.clone(), (&file).into(), None)),
|
||||
#[cfg(feature = "unstable-msc3552")]
|
||||
image: Some(Box::new(ImageContent::default())),
|
||||
image: Some(Box::default()),
|
||||
#[cfg(feature = "unstable-msc3552")]
|
||||
thumbnail: None,
|
||||
#[cfg(feature = "unstable-msc3552")]
|
||||
|
@ -139,7 +139,7 @@ impl VideoMessageEventContent {
|
||||
#[cfg(feature = "unstable-msc3553")]
|
||||
file: Some(FileContent::encrypted(file.url.clone(), (&file).into(), None)),
|
||||
#[cfg(feature = "unstable-msc3553")]
|
||||
video: Some(Box::new(VideoContent::default())),
|
||||
video: Some(Box::default()),
|
||||
#[cfg(feature = "unstable-msc3553")]
|
||||
thumbnail: None,
|
||||
#[cfg(feature = "unstable-msc3553")]
|
||||
|
@ -91,7 +91,7 @@ impl UserId {
|
||||
|
||||
/// Returns the user's localpart.
|
||||
pub fn localpart(&self) -> &str {
|
||||
&self.as_str()[1..self.colon_idx() as usize]
|
||||
&self.as_str()[1..self.colon_idx()]
|
||||
}
|
||||
|
||||
/// Returns the server name of the user ID.
|
||||
|
Loading…
x
Reference in New Issue
Block a user