refactor: replace for with for_each
This commit is contained in:
parent
c39d48fd07
commit
d1fb0ca78a
1 changed files with 4 additions and 4 deletions
|
|
@ -75,10 +75,10 @@ impl State {
|
|||
.map(|value| Graph::new(value))
|
||||
.collect();
|
||||
} else {
|
||||
for (graph, value) in self.cpu_graphs.iter_mut().zip(snapshot.cpus.into_iter())
|
||||
{
|
||||
graph.update(value);
|
||||
}
|
||||
self.cpu_graphs
|
||||
.iter_mut()
|
||||
.zip(snapshot.cpus.into_iter())
|
||||
.for_each(|(graph, value)| graph.update(value));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue