Reflow some lines manually

This commit is contained in:
Jake Howard
2021-03-31 21:45:05 +01:00
parent 0af3956abd
commit 93c881a7a9
4 changed files with 9 additions and 12 deletions

View File

@ -281,10 +281,7 @@ fn enforce_personal_ownership_policy(data: &CipherData, headers: &Headers, conn:
let user_uuid = &headers.user.uuid;
let policy_type = OrgPolicyType::PersonalOwnership;
if OrgPolicy::is_applicable_to_user(user_uuid, policy_type, conn) {
err!(
"Due to an Enterprise Policy, you are restricted from \
saving items to your personal vault."
)
err!("Due to an Enterprise Policy, you are restricted from saving items to your personal vault.")
}
}
Ok(())

View File

@ -141,11 +141,7 @@ pub fn validate_totp_code(user_uuid: &str, totp_code: u64, secret: &str, ip: &Cl
// The amount of steps back and forward in time
// Also check if we need to disable time drifted TOTP codes.
// If that is the case, we set the steps to 0 so only the current TOTP is valid.
let steps: i64 = if CONFIG.authenticator_disable_time_drift() {
0
} else {
1
};
let steps = !CONFIG.authenticator_disable_time_drift() as i64;
for step in -steps..=steps {
let time_step = current_timestamp / 30i64 + step;