refactor: comments

This commit is contained in:
xystrive 2024-07-25 13:23:16 +01:00
parent 6ef5221c2c
commit d188fe49b5
No known key found for this signature in database
GPG Key ID: 5EC5BBA34DEE94B7
2 changed files with 7 additions and 2 deletions

View File

@ -236,13 +236,14 @@ impl ChorusUser {
} }
/// Sends a request to complete an MFA challenge. /// Sends a request to complete an MFA challenge.
/// # Reference
/// See <https://docs.discord.sex/authentication#verify-mfa>
/// ///
/// If successful, the MFA verification JWT returned is set on the current [ChorusUser] executing the /// If successful, the MFA verification JWT returned is set on the current [ChorusUser] executing the
/// request. /// request.
/// ///
/// The JWT token expires after 5 minutes. /// The JWT token expires after 5 minutes.
///
/// # Reference
/// See <https://docs.discord.sex/authentication#verify-mfa>
pub async fn complete_mfa_challenge(&mut self, mfa_verify_schema: MfaVerifySchema) -> ChorusResult<()> { pub async fn complete_mfa_challenge(&mut self, mfa_verify_schema: MfaVerifySchema) -> ChorusResult<()> {
let endpoint_url = self.belongs_to.read().unwrap().urls.api.clone() + "/mfa/finish"; let endpoint_url = self.belongs_to.read().unwrap().urls.api.clone() + "/mfa/finish";
let chorus_request = ChorusRequest { let chorus_request = ChorusRequest {

View File

@ -1,3 +1,7 @@
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
use chrono::{DateTime, Utc}; use chrono::{DateTime, Utc};
#[derive(Debug, Clone)] #[derive(Debug, Clone)]