mirror of
https://github.com/storytold/designcraft.git
synced 2026-10-25 18:56:50 -06:00
fix clippy (sections)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
27ad9eb24a
commit
7b35e648b3
@@ -187,10 +187,8 @@ pub fn specs() -> Vec<CommandSpec> {
|
||||
let p = p.clone();
|
||||
s.edit(|d, _| {
|
||||
d.sections.retain(|x| x.start != start || start == 0);
|
||||
if p.get("remove").and_then(Value::as_bool).unwrap_or(false) {
|
||||
if start != 0 {
|
||||
return ok();
|
||||
}
|
||||
if p.get("remove").and_then(Value::as_bool).unwrap_or(false) && start != 0 {
|
||||
return ok();
|
||||
}
|
||||
let mut sec = d.sections.iter().find(|x| x.start == start).cloned().unwrap_or(designcraft_doc::Section {
|
||||
start,
|
||||
|
||||
Reference in New Issue
Block a user