From 7a8ca45bbee7b82d01e479abdc8856faa2797585 Mon Sep 17 00:00:00 2001 From: Charles Hall Date: Wed, 2 Oct 2024 10:03:06 -0700 Subject: [PATCH] client-api: allow constructing ErrorBody::NotJson --- crates/ruma-client-api/CHANGELOG.md | 1 + crates/ruma-client-api/src/error.rs | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/ruma-client-api/CHANGELOG.md b/crates/ruma-client-api/CHANGELOG.md index 9dd39e5c..1a27d78c 100644 --- a/crates/ruma-client-api/CHANGELOG.md +++ b/crates/ruma-client-api/CHANGELOG.md @@ -37,6 +37,7 @@ Improvements: - Add the `get_login_token` field to `Capabilities`, according to a clarification in the spec. - Add support for account locking, according to MSC3939. +- Allow constructing `error::ErrorBody::NotJson` outside of this crate. Bug fixes: diff --git a/crates/ruma-client-api/src/error.rs b/crates/ruma-client-api/src/error.rs index dae4a849..27ccbe6c 100644 --- a/crates/ruma-client-api/src/error.rs +++ b/crates/ruma-client-api/src/error.rs @@ -316,7 +316,6 @@ pub enum ErrorBody { Json(JsonValue), /// A response body that is not valid JSON. - #[non_exhaustive] NotJson { /// The raw bytes of the response body. bytes: Bytes,