Skip to content

Commit

Permalink
Merge branch 'main' into d-to-dt-tz-fix
Browse files Browse the repository at this point in the history
  • Loading branch information
sydney-runkle committed Feb 15, 2024
2 parents 9ca9b43 + fadeecc commit c12d82c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/errors/value_exception.rs
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ impl PydanticCustomError {

fn __repr__(&self, py: Python) -> PyResult<String> {
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)),
}
Expand Down Expand Up @@ -173,7 +173,7 @@ impl PydanticKnownError {

fn __repr__(&self, py: Python) -> PyResult<String> {
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(),
Expand Down

0 comments on commit c12d82c

Please sign in to comment.