diff --git a/rslib/src/error/mod.rs b/rslib/src/error/mod.rs index b2dd0f727..400a2a602 100644 --- a/rslib/src/error/mod.rs +++ b/rslib/src/error/mod.rs @@ -75,6 +75,7 @@ impl AnkiError { } AnkiError::ParseNumError => tr.errors_parse_number_fail().into(), AnkiError::FilteredDeckError(err) => err.localized_description(tr), + AnkiError::InvalidRegex(err) => format!("
{}", err), _ => format!("{:?}", self), } } diff --git a/rslib/src/error/search.rs b/rslib/src/error/search.rs index e0a751eed..9fb168fe6 100644 --- a/rslib/src/error/search.rs +++ b/rslib/src/error/search.rs @@ -34,7 +34,6 @@ pub enum SearchErrorKind { InvalidPositiveWholeNumber { provided: String, context: String }, InvalidNegativeWholeNumber { provided: String, context: String }, InvalidAnswerButton { provided: String, context: String }, - Regex(String), Other(Option
`{}`", text.replace('`', "'")).into() - } SearchErrorKind::Other(Some(info)) => info.into(), SearchErrorKind::Other(None) => tr.search_invalid_other(), SearchErrorKind::InvalidNumber { provided, context } => {