client-api: Change serialized name of thirdparty_id_creds in compat mode

This commit is contained in:
Jonas Platte 2021-11-03 18:08:37 +01:00
parent 0ea6dca815
commit d4df8ac76d
No known key found for this signature in database
GPG Key ID: CC154DE0E30B7C67

View File

@ -523,8 +523,8 @@ impl IncomingOAuth2 {
#[serde(tag = "type", rename = "m.login.email.identity")]
pub struct EmailIdentity<'a> {
/// Thirdparty identifier credentials.
#[serde(rename = "threepidCreds")]
#[cfg_attr(feature = "compat", alias = "threepid_creds")]
#[cfg_attr(not(feature = "compat"), serde(rename = "threepidCreds"))]
#[cfg_attr(feature = "compat", rename = "threepid_creds", alias = "threepidCreds")]
pub thirdparty_id_creds: &'a [ThirdpartyIdCredentials],
/// The value of the session key given by the homeserver, if any.
@ -551,8 +551,8 @@ impl IncomingEmailIdentity {
#[serde(tag = "type", rename = "m.login.msisdn")]
pub struct Msisdn<'a> {
/// Thirdparty identifier credentials.
#[serde(rename = "threepidCreds")]
#[cfg_attr(feature = "compat", alias = "threepid_creds")]
#[cfg_attr(not(feature = "compat"), serde(rename = "threepidCreds"))]
#[cfg_attr(feature = "compat", rename = "threepid_creds", alias = "threepidCreds")]
pub thirdparty_id_creds: &'a [ThirdpartyIdCredentials],
/// The value of the session key given by the homeserver, if any.