Skip to content

Commit

Permalink
Use more correct slice type
Browse files Browse the repository at this point in the history
Co-authored-by: Ruben De Smet <[email protected]>
  • Loading branch information
direc85 and rubdos committed Oct 3, 2024
1 parent b8d7761 commit aac50db
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions libsignal-service/src/master_key.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ impl MasterKey {
}

pub fn from_slice(
slice: &Vec<u8>,
slice: &[u8],
) -> Result<Self, std::array::TryFromSliceError> {
let inner = slice.as_slice().try_into()?;
let inner = slice.try_into()?;
Ok(Self { inner })
}
}
Expand Down Expand Up @@ -53,9 +53,9 @@ impl StorageServiceKey {
}

pub fn from_slice(
slice: &Vec<u8>,
slice: &[u8],
) -> Result<Self, std::array::TryFromSliceError> {
let inner = slice.as_slice().try_into()?;
let inner = slice.try_into()?;
Ok(Self { inner })
}
}
Expand Down

0 comments on commit aac50db

Please sign in to comment.