소스 검색

One last Clippy fix

Benjamin Sago 4 년 전
부모
커밋
0319130315
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      src/output.rs

+ 2 - 2
src/output.rs

@@ -202,8 +202,8 @@ impl TextFormat {
                     loc.size,
                     loc.horizontal_precision,
                     loc.vertical_precision,
-                    loc.latitude.map(|e| e.to_string()).unwrap_or_else(|| "Out of range".into()),
-                    loc.longitude.map(|e| e.to_string()).unwrap_or_else(|| "Out of range".into()),
+                    loc.latitude .map_or_else(|| "Out of range".into(), |e| e.to_string()),
+                    loc.longitude.map_or_else(|| "Out of range".into(), |e| e.to_string()),
                     loc.altitude,
                 )
             }