We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
.clone()
1 parent 5d53235 commit 8879fa7Copy full SHA for 8879fa7
src/input.rs
@@ -210,8 +210,8 @@ impl Opts {
210
211
// Only use top ports when the user asks for them
212
if self.top && config.ports.is_some() {
213
- let mut ports: Vec<u16> = Vec::with_capacity(config.ports.clone().unwrap().len());
214
- for entry in config.ports.clone().unwrap().keys() {
+ let mut ports: Vec<u16> = Vec::with_capacity(config.ports.as_ref().unwrap().len());
+ for entry in config.ports.as_ref().unwrap().keys() {
215
ports.push(entry.parse().unwrap());
216
}
217
self.ports = Some(ports);
0 commit comments