client-api: Fix compat workaround for Element

This commit is contained in:
Jonas Platte 2021-09-21 13:40:44 +02:00
parent 8079e1c155
commit 630c1b1d01
No known key found for this signature in database
GPG Key ID: CC154DE0E30B7C67
2 changed files with 4 additions and 3 deletions

View File

@ -1,5 +1,8 @@
# [unreleased] # [unreleased]
* Add a `feature = "compat"` workaround for Element failing on `GET /_matrix/client/r0/account/3pid`
response if the optional `threepids` field is missing
# 0.12.2 # 0.12.2
Improvements Improvements
@ -31,8 +34,6 @@ Improvements:
``` ```
* Add unstable support for room knocking * Add unstable support for room knocking
* Add unstable support for reasons for leaving rooms * Add unstable support for reasons for leaving rooms
* Add a `feature = "compat"` workaround for Element failing on `GET /_matrix/client/r0/account/3pid`
response if the optional `threepids` field is missing
# 0.11.2 # 0.11.2

View File

@ -19,7 +19,7 @@ ruma_api! {
response: { response: {
/// A list of third party identifiers the homeserver has associated with the user's account. /// A list of third party identifiers the homeserver has associated with the user's account.
#[serde(default)] #[serde(default)]
#[cfg_attr(feature = "compat", serde(skip_serializing_if = "Vec::is_empty"))] #[cfg_attr(not(feature = "compat"), serde(skip_serializing_if = "Vec::is_empty"))]
pub threepids: Vec<ThirdPartyIdentifier>, pub threepids: Vec<ThirdPartyIdentifier>,
} }