bitwarden_vault/
totp_client.rsuse chrono::{DateTime, Utc};
use crate::{
generate_totp, generate_totp_cipher_view, CipherListView, TotpError, TotpResponse, VaultClient,
};
impl<'a> VaultClient<'a> {
pub fn generate_totp(
&'a self,
key: String,
time: Option<DateTime<Utc>>,
) -> Result<TotpResponse, TotpError> {
generate_totp(key, time)
}
pub fn generate_totp_cipher_view(
&'a self,
view: CipherListView,
time: Option<DateTime<Utc>>,
) -> Result<TotpResponse, TotpError> {
let enc = self.client.internal.get_encryption_settings()?;
generate_totp_cipher_view(&enc, view, time)
}
}