Skip to content

Commit bc0f5a7

Browse files
author
Adrian
committed
Fix clippy warnings
1 parent cdd4517 commit bc0f5a7

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

mp4parse/src/unstable.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -498,7 +498,7 @@ pub struct Microseconds<T>(pub T);
498498
pub fn media_time_to_us(time: MediaScaledTime, scale: MediaTimeScale) -> Option<Microseconds<u64>> {
499499
let microseconds_per_second = 1_000_000;
500500
rational_scale::<u64, u64>(time.0, scale.0, microseconds_per_second)
501-
.and_then(|v| Some(Microseconds(v)))
501+
.map(|v| Microseconds(v))
502502
}
503503

504504
/// Convert `time` in track's local (mdhd) timescale to microseconds,
@@ -513,7 +513,7 @@ where
513513
assert_eq!(time.1, scale.1);
514514
let microseconds_per_second = 1_000_000;
515515
rational_scale::<T, u64>(time.0, scale.0, microseconds_per_second)
516-
.and_then(|v| Some(Microseconds(v)))
516+
.map(|v| Microseconds(v))
517517
}
518518

519519
#[test]

0 commit comments

Comments
 (0)