Skip to content

Commit 4aa211e

Browse files
committed
Replace zero-index call to get() with first()
Suggested by Clippy.
1 parent 8ca15c9 commit 4aa211e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/export-svg.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ fn main() -> Result<(), String> {
107107
.unwrap_or_else(|| "track.svg".to_string());
108108
let scale = matches.opt_get_default("scale", ExportScale::default())
109109
.map_err(|err| format!("Invalid scale option value: {}", err))?;
110-
let filename = match matches.free.get(0) {
110+
let filename = match matches.free.first() {
111111
Some(val) => val,
112112
None => {
113113
eprintln!("Usage: {} [options] <input-file.rgt>", program);

0 commit comments

Comments
 (0)