client-api: Fix todo comment formatting
This commit is contained in:
parent
d09c961a0b
commit
f4a8ef6306
@ -3,7 +3,7 @@
|
|||||||
pub mod add_3pid;
|
pub mod add_3pid;
|
||||||
pub mod bind_3pid;
|
pub mod bind_3pid;
|
||||||
pub mod change_password;
|
pub mod change_password;
|
||||||
#[cfg(feature = "unstable-spec")] // todo: v1.2
|
#[cfg(feature = "unstable-spec")] // todo: v1.2
|
||||||
pub mod check_registration_token_validity;
|
pub mod check_registration_token_validity;
|
||||||
pub mod deactivate;
|
pub mod deactivate;
|
||||||
pub mod delete_3pid;
|
pub mod delete_3pid;
|
||||||
|
@ -210,7 +210,7 @@ impl IncomingAuthData {
|
|||||||
Self::EmailIdentity(_) => Some(AuthType::EmailIdentity),
|
Self::EmailIdentity(_) => Some(AuthType::EmailIdentity),
|
||||||
Self::Msisdn(_) => Some(AuthType::Msisdn),
|
Self::Msisdn(_) => Some(AuthType::Msisdn),
|
||||||
Self::Dummy(_) => Some(AuthType::Dummy),
|
Self::Dummy(_) => Some(AuthType::Dummy),
|
||||||
#[cfg(feature = "unstable-spec")] // todo: v1.2
|
#[cfg(feature = "unstable-spec")] // todo: v1.2
|
||||||
Self::RegistrationToken(_) => Some(AuthType::RegistrationToken),
|
Self::RegistrationToken(_) => Some(AuthType::RegistrationToken),
|
||||||
Self::FallbackAcknowledgement(_) => None,
|
Self::FallbackAcknowledgement(_) => None,
|
||||||
Self::_Custom(c) => Some(AuthType::_Custom(PrivOwnedStr(c.auth_type.as_str().into()))),
|
Self::_Custom(c) => Some(AuthType::_Custom(PrivOwnedStr(c.auth_type.as_str().into()))),
|
||||||
@ -227,7 +227,7 @@ impl IncomingAuthData {
|
|||||||
Self::EmailIdentity(x) => x.session.as_deref(),
|
Self::EmailIdentity(x) => x.session.as_deref(),
|
||||||
Self::Msisdn(x) => x.session.as_deref(),
|
Self::Msisdn(x) => x.session.as_deref(),
|
||||||
Self::Dummy(x) => x.session.as_deref(),
|
Self::Dummy(x) => x.session.as_deref(),
|
||||||
#[cfg(feature = "unstable-spec")] // todo: v1.2
|
#[cfg(feature = "unstable-spec")] // todo: v1.2
|
||||||
Self::RegistrationToken(x) => x.session.as_deref(),
|
Self::RegistrationToken(x) => x.session.as_deref(),
|
||||||
Self::FallbackAcknowledgement(x) => Some(&x.session),
|
Self::FallbackAcknowledgement(x) => Some(&x.session),
|
||||||
Self::_Custom(x) => x.session.as_deref(),
|
Self::_Custom(x) => x.session.as_deref(),
|
||||||
@ -270,7 +270,7 @@ impl IncomingAuthData {
|
|||||||
thirdparty_id_creds: &x.thirdparty_id_creds,
|
thirdparty_id_creds: &x.thirdparty_id_creds,
|
||||||
session: None,
|
session: None,
|
||||||
})),
|
})),
|
||||||
#[cfg(feature = "unstable-spec")] // todo: v1.2
|
#[cfg(feature = "unstable-spec")] // todo: v1.2
|
||||||
Self::RegistrationToken(x) => {
|
Self::RegistrationToken(x) => {
|
||||||
Cow::Owned(serialize(RegistrationToken { token: &x.token, session: None }))
|
Cow::Owned(serialize(RegistrationToken { token: &x.token, session: None }))
|
||||||
}
|
}
|
||||||
|
@ -65,7 +65,7 @@ fn deserialize_auth_data_direct_request() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
#[cfg(feature = "unstable-spec")] // todo: v1.2
|
#[cfg(feature = "unstable-spec")] // todo: v1.2
|
||||||
fn serialize_auth_data_registration_token() {
|
fn serialize_auth_data_registration_token() {
|
||||||
let auth_data = AuthData::RegistrationToken(
|
let auth_data = AuthData::RegistrationToken(
|
||||||
assign!(uiaa::RegistrationToken::new("mytoken"), { session: Some("session") }),
|
assign!(uiaa::RegistrationToken::new("mytoken"), { session: Some("session") }),
|
||||||
@ -82,7 +82,7 @@ fn serialize_auth_data_registration_token() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
#[cfg(feature = "unstable-spec")] // todo: v1.2
|
#[cfg(feature = "unstable-spec")] // todo: v1.2
|
||||||
fn deserialize_auth_data_registration_token() {
|
fn deserialize_auth_data_registration_token() {
|
||||||
let json = json!({
|
let json = json!({
|
||||||
"type": "m.login.registration_token",
|
"type": "m.login.registration_token",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user