mirror of
https://github.com/iluvcapra/bwavfile.git
synced 2026-11-16 00:34:13 +00:00
clippy: Use Vec::get() instead of iter().nth()
This commit is contained in:
1 parent
b6c20ae410
commit
6989520743
1 file changed
+1
-1
+1
-1
@@ -622,7 +622,7 @@ impl<R: Read + Seek> WaveReader<R> {
|
||||
fourcc: FourCC,
|
||||
index: u32,
|
||||
) -> Result<(u64, u64), ParserError> {
|
||||
if let Some((start, length)) = self.get_chunks_extents(fourcc)?.iter().nth(index as usize) {
|
||||
if let Some((start, length)) = self.get_chunks_extents(fourcc)?.get(index as usize) {
|
||||
Ok((*start, *length))
|
||||
} else {
|
||||
Err(ParserError::ChunkMissing { signature: fourcc })
|
||||
|
||||
Reference in new issue
Block a user