Commit 67a91ca8 authored by Robert Czechowski's avatar Robert Czechowski
Browse files

Reduce amount of ignored clippy lints

parent e03154a0
Pipeline #205 passed with stage
in 5 minutes and 10 seconds
......@@ -11,6 +11,6 @@ format:
cargo +nightly fmt
clippy:
cargo clippy --all-targets --all-features -- -D warnings -A clippy::redundant_field_names -A clippy::useless_format -A clippy::let_and_return -A clippy::type_complexity -A clippy::option_map_unit_fn -A clippy::too_many_arguments -A clippy::redundant_closure -A clippy::identity_conversion -A clippy::expect_fun_call
cargo clippy --all-targets --all-features -- -D warnings -A clippy::redundant_field_names -A clippy::useless_format -A clippy::let_and_return -A clippy::type_complexity -A clippy::option_map_unit_fn -A clippy::identity_conversion -A clippy::expect_fun_call
......@@ -31,7 +31,6 @@ pub struct ContestInfo {
pub tasks: Vec<TaskInfo>,
}
#[allow(dead_code)] //CsrfCheckFailed, SessionTimeout, DatabaseError and UnmatchedPasswords are used in webfw_iron.rs.
#[derive(Clone)]
pub enum MedalError {
NotLoggedIn,
......@@ -651,9 +650,7 @@ impl std::convert::Into<String> for ProfileStatus {
}
pub fn edit_profile<T: MedalConnection>(conn: &T, session_token: &str, user_id: Option<i32>, csrf_token: &str,
firstname: String, lastname: String, street: Option<String>,
zip: Option<String>, city: Option<String>, password: Option<String>,
password_repeat: Option<String>, grade: i32)
(firstname, lastname, street, zip, city, password, password_repeat, grade): (String, String,Option<String>,Option<String>,Option<String>,Option<String>,Option<String>,i32))
-> MedalResult<ProfileStatus>
{
let mut session = conn.get_session(&session_token)
......
......@@ -580,14 +580,7 @@ fn profile_post<C>(req: &mut Request) -> IronResult<Response>
&session_token,
None,
&csrf_token,
firstname,
lastname,
street,
zip,
city,
pwd,
pwd_repeat,
grade].aug(req)?;
(firstname, lastname, street, zip, city, pwd, pwd_repeat, grade)].aug(req)?;
Ok(Response::with((status::Found,
Redirect(iron::Url::parse(&format!("{}?status={:?}",
......@@ -632,14 +625,7 @@ fn user_post<C>(req: &mut Request) -> IronResult<Response>
&session_token,
Some(user_id),
&csrf_token,
firstname,
lastname,
street,
zip,
city,
pwd,
pwd_repeat,
grade].aug(req)?;
(firstname, lastname, street, zip, city, pwd, pwd_repeat, grade)].aug(req)?;
Ok(Response::with((status::Found,
Redirect(iron::Url::parse(&format!("{}?status={:?}",
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment