We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 444eb77 commit 8a8bc06Copy full SHA for 8a8bc06
crates/bitwarden-crypto/src/signing/namespace.rs
@@ -46,9 +46,9 @@ impl TryFrom<i128> for SigningNamespace {
46
type Error = CryptoError;
47
48
fn try_from(value: i128) -> Result<Self, Self::Error> {
49
- if value < i64::MIN as i128 || value > i64::MAX as i128 {
+ let Ok(value) = i64::try_from(value) else {
50
return Err(SignatureError::InvalidNamespace.into());
51
- }
52
- Self::try_from(value as i64)
+ };
+ Self::try_from(value)
53
}
54
0 commit comments