Skip to content

Commit

Permalink
Small improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
yukibtc committed Nov 23, 2022
1 parent f542b8a commit 2a9c4ba
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/dispatcher/auth.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// Copyright (c) 2022 Yuki Kishimoto
// Distributed under the MIT software license

#[derive(Clone)]
pub struct Auth {
username: String,
password: String,
Expand Down
1 change: 1 addition & 0 deletions src/dispatcher/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ use url::Url;
use super::{Auth, Dispatcher};
use crate::error::NtfyError;

#[derive(Clone)]
pub struct DispatcherBuilder {
url: String,
auth: Option<Auth>,
Expand Down
2 changes: 1 addition & 1 deletion src/dispatcher/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ pub struct Dispatcher {

impl Dispatcher {
/// Create new dispatcher
pub fn new<S>(url: S, auth: Option<Auth>, proxy: Option<&str>) -> Result<Self, NtfyError>
pub fn new<S>(url: S, auth: Option<Auth>, proxy: Option<S>) -> Result<Self, NtfyError>
where
S: Into<String>,
{
Expand Down
3 changes: 3 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
#[macro_use]
extern crate serde;

pub use chrono::{Duration, Local};
pub use url::Url;

pub mod dispatcher;
pub mod error;
mod net;
Expand Down

0 comments on commit 2a9c4ba

Please sign in to comment.