Fix clippy issues
All checks were successful
Check, lint and test / Check, lint and test (push) Successful in 49s

This commit is contained in:
Paul van Tilburg 2024-07-26 22:45:30 +02:00
parent 526c3aa30c
commit e73f4ff661
Signed by: paul
GPG key ID: C6DE073EDA9EEC4D
2 changed files with 2 additions and 7 deletions

View file

@ -41,6 +41,7 @@ pub(crate) enum Backends {
#[enum_dispatch]
pub(crate) trait Backend {
/// Returns the name of the backend.
#[allow(unused)] // For future use!
fn name(&self) -> &'static str;
/// Returns the channel with its currently contained content items.

View file

@ -20,13 +20,7 @@ use crate::Config;
/// It requires the backend and configuration to be able to construct download URLs.
pub(crate) fn construct(backend_id: &str, config: &Config, channel: Channel) -> rss::Channel {
let category = CategoryBuilder::default()
.name(
channel
.categories
.first()
.map(Clone::clone)
.unwrap_or_default(),
)
.name(channel.categories.first().cloned().unwrap_or_default())
.build();
let unix_timestamp = NaiveDateTime::from_timestamp_opt(0, 0)
.expect("Out-of-range seconds or invalid nanoseconds");