diff --git a/core/src/id.rs b/core/src/id.rs index 565cf3c306..3fc74ce925 100644 --- a/core/src/id.rs +++ b/core/src/id.rs @@ -44,9 +44,9 @@ impl From for Id { } // Not meant to be used directly -impl Into for Id { - fn into(self) -> NonZeroU128 { - match &self.0 { +impl From for NonZeroU128 { + fn from(id: Id) -> NonZeroU128 { + match &id.0 { Internal::Unique(id) => NonZeroU128::try_from(*id as u128).unwrap(), Internal::Custom(id, _) => { NonZeroU128::try_from(*id as u128).unwrap()