Skip to content

use config object instead of single val#181

Merged
harlanc merged 1 commit intoharlanc:masterfrom
nikitos:notify_params
Mar 6, 2026
Merged

use config object instead of single val#181
harlanc merged 1 commit intoharlanc:masterfrom
nikitos:notify_params

Conversation

@nikitos
Copy link
Copy Markdown
Contributor

@nikitos nikitos commented Feb 16, 2026

No description provided.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refactors HttpNotifier::new to accept a single HttpNotifierConfig object instead of five individual Option<String> URL parameters. This simplifies the constructor's API and aligns it with the pattern used by other components that accept config structs from the config crate.

Changes:

  • HttpNotifier::new now takes a HttpNotifierConfig struct instead of individual URL fields, and the unused PublisherInfo import is removed.
  • The call site in service.rs is updated to pass httpnotifier.clone() directly.
  • The config crate is added as a dependency of streamhub in Cargo.toml and Cargo.lock.

Reviewed changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated no comments.

File Description
library/streamhub/src/notify/http.rs Refactors HttpNotifier::new to accept HttpNotifierConfig object; removes unused PublisherInfo import
application/xiu/src/service.rs Updates call site to pass httpnotifier.clone() instead of individual fields
library/streamhub/Cargo.toml Adds config crate as a dependency
Cargo.lock Records the new config dependency for streamhub

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@harlanc harlanc merged commit 93500d6 into harlanc:master Mar 6, 2026
5 checks passed
@harlanc
Copy link
Copy Markdown
Owner

harlanc commented Mar 6, 2026

Thanks for your contributions!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants