Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
Make assert conditions more uniform.
  • Loading branch information
PetrGlad committed Nov 14, 2024
1 parent de29cb3 commit 6734d01
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/buffer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ where
where
D: Into<Vec<S>>,
{
assert!(channels > 0);
assert!(sample_rate > 0);
assert!(channels >= 1);
assert!(sample_rate >= 1);

let data = data.into();
let duration_ns = 1_000_000_000u64.checked_mul(data.len() as u64).unwrap()
Expand Down

0 comments on commit 6734d01

Please sign in to comment.