Skip to content

Commit 7e40878

Browse files
committed
Run cargo fmt
1 parent 302a3b5 commit 7e40878

File tree

2 files changed

+10
-6
lines changed

2 files changed

+10
-6
lines changed

crates/bitwarden-auth/src/registration.rs

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,9 @@ use std::str::FromStr;
1010
use bitwarden_api_api::models::{
1111
DeviceKeysRequestModel, KeysRequestModel, OrganizationUserResetPasswordEnrollmentRequestModel,
1212
};
13-
use bitwarden_core::key_management::account_cryptographic_state::WrappedAccountCryptographicState;
14-
use bitwarden_core::{Client, UserId};
13+
use bitwarden_core::{
14+
Client, UserId, key_management::account_cryptographic_state::WrappedAccountCryptographicState,
15+
};
1516
use bitwarden_encoding::B64;
1617
use bitwarden_error::bitwarden_error;
1718
use serde_bytes::ByteBuf;
@@ -45,12 +46,14 @@ impl RegistrationClient {
4546
// Do API request here. It will be authenticated using the client's tokens.
4647
}
4748

48-
/// Initializes a new cryptographic state for a user and posts it to the server; enrolls in admin password reset and finally enrolls the user to TDE unlock.
49+
/// Initializes a new cryptographic state for a user and posts it to the server; enrolls in
50+
/// admin password reset and finally enrolls the user to TDE unlock.
4951
pub async fn post_keys_for_tde_registration(
5052
&self,
5153
org_id: String,
5254
org_public_key: B64,
53-
// Note: Ideally these would be set for the register client, however no such functionality exists at the moment
55+
// Note: Ideally these would be set for the register client, however no such functionality
56+
// exists at the moment
5457
user_id: String,
5558
device_id: String,
5659
trust_device: bool,
@@ -128,7 +131,8 @@ impl RegistrationClient {
128131
}
129132

130133
info!("User initialized!");
131-
// Note: This passing out of state and keys is temporary. Once SDK state management is more mature, the account cryptographic state and keys should be set directly here.
134+
// Note: This passing out of state and keys is temporary. Once SDK state management is more
135+
// mature, the account cryptographic state and keys should be set directly here.
132136
Ok(TdeRegistrationResult {
133137
account_cryptographic_state: cryptography_state,
134138
device_key: device_key_set.device_key.to_string(),

crates/bitwarden-core/src/key_management/crypto.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ use {tsify::Tsify, wasm_bindgen::prelude::*};
2323
use crate::{
2424
Client, NotAuthenticatedError, OrganizationId, UserId, WrongPasswordError,
2525
client::{LoginMethod, UserLoginMethod, encryption_settings::EncryptionSettingsError},
26-
error::{StatefulCryptoError, UserIdAlreadySetError},
26+
error::StatefulCryptoError,
2727
key_management::{
2828
AsymmetricKeyId, SecurityState, SignedSecurityState, SigningKeyId, SymmetricKeyId,
2929
account_cryptographic_state::WrappedAccountCryptographicState,

0 commit comments

Comments
 (0)