Fixed new clippy lint in rust 1.65.0 (#603)

This commit is contained in:
Trangar 2022-11-22 16:25:18 +01:00 committed by GitHub
parent cbf4d46073
commit 55d66480f5
1 changed files with 1 additions and 1 deletions

View File

@ -31,7 +31,7 @@ impl<T> Encode for PhantomData<T> {
impl Encode for bool {
fn encode<E: Encoder>(&self, encoder: &mut E) -> Result<(), EncodeError> {
if *self { 1u8 } else { 0u8 }.encode(encoder)
u8::from(*self).encode(encoder)
}
}