Skip to content

Commit

Permalink
style: Fix clippy warnings
Browse files Browse the repository at this point in the history
Fixes the following warnings:

    warning: can be more succinctly written as a byte str
       --> src/tag/format/enveloped.rs:89:43
        |
    89  |             bytes_written += writer.write(&[b'\n'])?;
        |                                           ^^^^^^^^ help: try: `b"\n"`
        |
        = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#byte_char_slices
    note: the lint level is defined here
       --> src/lib.rs:121:9
        |
    121 | #![deny(clippy::all)]
        |         ^^^^^^^^^^^
        = note: `#[warn(clippy::byte_char_slices)]` implied by `#[warn(clippy::all)]`

    warning: doc list item without indentation
      --> src/lib.rs:95:5
       |
    95 | //! `_Serato_/Metadata` directory instead. No support has been added yet.
       |     ^
       |
       = help: if this is supposed to be its own paragraph, add a blank line
       = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_lazy_continuation
       = note: `#[warn(clippy::doc_lazy_continuation)]` implied by `#[warn(clippy::all)]`
    help: indent this line
       |
    95 | //!   `_Serato_/Metadata` directory instead. No support has been added yet.
       |     ++
  • Loading branch information
Holzhaus committed Nov 14, 2024
1 parent 7347eda commit dae5821
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@
//! - The `Serato RelVolAd` and the `Serato VidAssoc` tags haven't been reverse engineed yet, but
//! preliminary support has been added. For now, they just return a tag version and a byte vector.
//! - AAC files (among others) do not store metadata in tags, and use XML files in the
//! `_Serato_/Metadata` directory instead. No support has been added yet.
//! `_Serato_/Metadata` directory instead. No support has been added yet.
//! - The cue colors stored in the metadata are *not* the same as displayed in Serato DJ Pro.
//! Instead, they uses the color palette from Serato DJ Into. Serato then maps them to a new
//! color palette. Support for converting between the two is currently missing.
Expand Down
2 changes: 1 addition & 1 deletion src/tag/format/enveloped.rs
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ pub fn base64_encode(writer: &mut impl io::Write, input: &[u8]) -> Result<usize,
bytes_written += writer.write(b"A")?;
}
} else {
bytes_written += writer.write(&[b'\n'])?;
bytes_written += writer.write(b"\n")?;
}
}
Ok(bytes_written)
Expand Down

0 comments on commit dae5821

Please sign in to comment.