Skip to content

Commit

Permalink
Bump version + cargo fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
Radiicall committed Feb 20, 2024
1 parent 85d4226 commit 0bb529c
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 9 deletions.
4 changes: 2 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions jellyfin-rpc-cli/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "jellyfin-rpc-cli"
version = "0.15.5"
version = "1.0.0"
edition = "2021"
description = "Displays the content you're currently watching on Discord!"
license = "GPL-3.0-or-later"
Expand All @@ -27,7 +27,7 @@ retry = "2.0"

[dependencies.jellyfin-rpc]
features = ["imgur", "cli"]
#version = "0.1.5"
#version = "1.0.0"
path = "../jellyfin-rpc"

[dependencies.clap]
Expand Down
7 changes: 5 additions & 2 deletions jellyfin-rpc-cli/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
use clap::Parser;
use colored::Colorize;
use discord_rich_presence::{activity, DiscordIpc, DiscordIpcClient};
pub use jellyfin_rpc::core::rpc::show_paused;
pub use jellyfin_rpc::prelude::*;
pub use jellyfin_rpc::services::imgur::*;
pub use jellyfin_rpc::core::rpc::show_paused;
use retry::retry_with_index;
#[cfg(feature = "updates")]
mod updates;
Expand Down Expand Up @@ -207,7 +207,10 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
}
}

if !content.media_type.is_none() && blacklist_check && show_paused(&content.media_type, content.endtime, &config.discord) {
if !content.media_type.is_none()
&& blacklist_check
&& show_paused(&content.media_type, content.endtime, &config.discord)
{
// Print what we're watching
if !connected {
println!(
Expand Down
2 changes: 1 addition & 1 deletion jellyfin-rpc/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "jellyfin-rpc"
version = "0.1.5"
version = "1.0.0"
edition = "2021"
description = "Backend for the Jellyfin-RPC-cli and Jellyfin-RPC-Iced projects"
license = "GPL-3.0-or-later"
Expand Down
8 changes: 6 additions & 2 deletions jellyfin-rpc/src/core/rpc.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
use crate::prelude::MediaType;
use super::config::Discord;
use crate::prelude::MediaType;
use discord_rich_presence::activity;

/// Used to set the activity on Discord.
Expand Down Expand Up @@ -55,7 +55,11 @@ pub fn setactivity<'a>(
new_activity
}

pub fn show_paused<'a>(media_type: &'a MediaType, endtime: Option<i64>, discord: &'a Option<Discord>) -> bool {
pub fn show_paused<'a>(
media_type: &'a MediaType,
endtime: Option<i64>,
discord: &'a Option<Discord>,
) -> bool {
if media_type == &MediaType::Book {
return true;
}
Expand Down

0 comments on commit 0bb529c

Please sign in to comment.