feat!: distinguish URLs and hosts

BREAKING CHANGE: the configuration for Bitmagnet and Ntfy has changed.
Instead of `host`, they now use `url`.
This commit is contained in:
Marc Plano-Lesay 2025-05-22 21:57:51 +10:00
parent 01fecffc90
commit bb32cfdf97
Signed by: kernald
GPG key ID: 66A41B08CC62A6CF
10 changed files with 59 additions and 50 deletions

View file

@ -1,6 +1,7 @@
use crate::app::Enableable;
use crate::config::types::{Host, Password, Topic, Username};
use crate::config::types::{Password, Topic, Username};
use serde::{Deserialize, Serialize};
use url::Url;
/// Configuration for the ntfy notification service
#[derive(Debug, Clone, Serialize, Deserialize)]
@ -9,8 +10,8 @@ pub struct NtfyConfig {
#[serde(default)]
pub enable: bool,
/// The host URL of the ntfy server
pub host: Host,
/// The URL of the ntfy server
pub url: Url,
/// The username for authentication (optional)
#[serde(default)]