diff --git a/rust/xaynet-mobile/src/settings.rs b/rust/xaynet-mobile/src/settings.rs index 50eab8532..f5baa9e22 100644 --- a/rust/xaynet-mobile/src/settings.rs +++ b/rust/xaynet-mobile/src/settings.rs @@ -46,8 +46,11 @@ impl Settings { } /// Set the scalar to use for masking + /// + /// # Panics + /// Panics if a `Scalar` cannot be constructed from the given `scalar`. pub fn set_scalar(&mut self, scalar: f64) { - self.scalar = Scalar::from_primitive(scalar).unwrap() // FIXME better to avoid f64 + self.scalar = Scalar::from_primitive(scalar).unwrap() } /// Set the Xaynet coordinator address