diff --git a/src/errors/value_exception.rs b/src/errors/value_exception.rs index 68f93d463..3152044d1 100644 --- a/src/errors/value_exception.rs +++ b/src/errors/value_exception.rs @@ -98,7 +98,7 @@ impl PydanticCustomError { fn __repr__(&self, py: Python) -> PyResult { let msg = self.message(py)?; - match { self.context.as_ref() } { + match self.context.as_ref() { Some(ctx) => Ok(format!("{msg} [type={}, context={}]", self.error_type, ctx.as_ref(py))), None => Ok(format!("{msg} [type={}, context=None]", self.error_type)), } @@ -173,7 +173,7 @@ impl PydanticKnownError { fn __repr__(&self, py: Python) -> PyResult { let msg = self.message(py)?; - match { self.context(py)?.as_ref() } { + match self.context(py)?.as_ref() { Some(ctx) => Ok(format!( "{msg} [type={}, context={}]", self.error_type(),