From c9457b342d0dabd66427258b62d01f9828cc7731 Mon Sep 17 00:00:00 2001 From: Felix Ableitner Date: Thu, 12 Dec 2024 15:30:35 +0100 Subject: [PATCH] remove error --- crates/utils/src/error.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/crates/utils/src/error.rs b/crates/utils/src/error.rs index f45bc271f..4f28aaa32 100644 --- a/crates/utils/src/error.rs +++ b/crates/utils/src/error.rs @@ -113,7 +113,6 @@ pub enum LemmyErrorType { SystemErrLogin, CouldntSetAllRegistrationsAccepted, CouldntSetAllEmailVerified, - Banned, BlockedUrl, CouldntGetComments, CouldntGetPosts, @@ -328,9 +327,9 @@ cfg_if! { #[test] fn deserializes_no_message() -> LemmyResult<()> { - let err = LemmyError::from(LemmyErrorType::Banned).error_response(); + let err = LemmyError::from(LemmyErrorType::BlockedUrl).error_response(); let json = String::from_utf8(err.into_body().try_into_bytes().unwrap_or_default().to_vec())?; - assert_eq!(&json, "{\"error\":\"banned\"}"); + assert_eq!(&json, "{\"error\":\"blocked_url\"}"); Ok(()) }