Skip to content

Commit

Permalink
lint: cargo fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
XMLHexagram committed Dec 3, 2024
1 parent 2d1e083 commit 369f8c2
Showing 1 changed file with 14 additions and 8 deletions.
22 changes: 14 additions & 8 deletions analysis/src/shared_utils/audio_metadata_reader.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,20 @@ pub fn get_format(file_path: &str) -> Result<Box<dyn FormatReader>> {
}

pub fn get_codec_information(track: &Track) -> Result<(u32, f64), symphonia::core::errors::Error> {
let sample_rate = track
.codec_params
.sample_rate
.ok_or(symphonia::core::errors::Error::Unsupported("No sample rate found"))?;
let duration = track
.codec_params
.n_frames
.ok_or(symphonia::core::errors::Error::Unsupported("No duration found"))?;
let sample_rate =
track
.codec_params
.sample_rate
.ok_or(symphonia::core::errors::Error::Unsupported(
"No sample rate found",
))?;
let duration =
track
.codec_params
.n_frames
.ok_or(symphonia::core::errors::Error::Unsupported(
"No duration found",
))?;

let time_base = track
.codec_params
Expand Down

0 comments on commit 369f8c2

Please sign in to comment.