Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
douweschulte committed Oct 23, 2024
1 parent 08e2bd5 commit ffcef71
Showing 1 changed file with 13 additions and 5 deletions.
18 changes: 13 additions & 5 deletions rustyms/src/identification/mztab.rs
Original file line number Diff line number Diff line change
Expand Up @@ -120,15 +120,21 @@ impl MZTabData {
"columnit_psm" => (),
m if m.starts_with("fixed_mod[") && m.ends_with(']') => (),
m if m.starts_with("variable_mod[") && m.ends_with(']') => (),
m if m.starts_with("psm_search_engine_score[") && m.ends_with(']') => (),
m if m.starts_with("psm_search_engine_score[") && m.ends_with(']') => {
()
}
m if m.starts_with("ms_run[") && m.ends_with("]-location") => (),
_ => ()
_ => (),
}
None
} else {
Some(Err(CustomError::error("Invalid MTD line", "MTD lines should contain three columns (the tag, key, and value)", Context::full_line(line_index, line))))
Some(Err(CustomError::error(
"Invalid MTD line",
"MTD lines should contain three columns (the tag, key, and value)",
Context::full_line(line_index, line),
)))
}
},
}
Ok(MZTabLine::PSH(line_index, line, fields)) => {
let header = fields
.into_iter()
Expand Down Expand Up @@ -228,7 +234,9 @@ impl MZTabData {
for (location, modification) in modifications {
match location {
0 => peptide.set_simple_n_term(Some(modification)),
c if c == peptide.len() + 1 => peptide.set_simple_c_term(Some(modification)),
c if c == peptide.len() + 1 => {
peptide.set_simple_c_term(Some(modification))
}
i => peptide.sequence_mut()[i - 1].add_simple_modification(modification),
}
}
Expand Down

0 comments on commit ffcef71

Please sign in to comment.