remove unneeded returns
Fixes the clippy warning: warning: unneeded `return` statement --> proxmox-tfa/src/api/mod.rs:468:17 | 468 | / return TfaResult::Failure { 469 | | needs_saving: true, 470 | | tfa_limit_reached, 471 | | totp_limit_reached, 472 | | }; | |_________________^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return = note: `#[warn(clippy::needless_return)]` on by default help: remove `return` | 468 ~ TfaResult::Failure { 469 + needs_saving: true, 470 + tfa_limit_reached, 471 + totp_limit_reached, 472 ~ } | Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
This commit is contained in:
parent
d07a0243f4
commit
a87d52dad3
@ -101,7 +101,7 @@ impl Context for PBSContext {
|
||||
}
|
||||
|
||||
fn default_config(&self) -> &'static str {
|
||||
return DEFAULT_CONFIG;
|
||||
DEFAULT_CONFIG
|
||||
}
|
||||
|
||||
fn lookup_template(
|
||||
|
@ -51,7 +51,7 @@ impl Context for PVEContext {
|
||||
}
|
||||
|
||||
fn default_config(&self) -> &'static str {
|
||||
return DEFAULT_CONFIG;
|
||||
DEFAULT_CONFIG
|
||||
}
|
||||
|
||||
fn lookup_template(
|
||||
|
@ -465,11 +465,11 @@ impl TfaConfig {
|
||||
Some(proxmox_time::epoch_i64() + access.tfa_failure_lock_time());
|
||||
}
|
||||
|
||||
return TfaResult::Failure {
|
||||
TfaResult::Failure {
|
||||
needs_saving: true,
|
||||
tfa_limit_reached,
|
||||
totp_limit_reached,
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user