mirror of
https://github.com/kristoferssolo/tg-relay-rs.git
synced 2026-02-25 05:08:15 +00:00
feat: add platforms as features
This commit is contained in:
@@ -1,9 +1,16 @@
|
||||
#[cfg(feature = "instagram")]
|
||||
mod instagram;
|
||||
#[cfg(feature = "youtube")]
|
||||
mod youtube;
|
||||
|
||||
use crate::error::Result;
|
||||
use teloxide::{Bot, types::ChatId};
|
||||
|
||||
#[cfg(feature = "instagram")]
|
||||
pub use instagram::InstagramHandler;
|
||||
#[cfg(feature = "youtube")]
|
||||
pub use youtube::YouTubeShortsHandler;
|
||||
|
||||
#[async_trait::async_trait]
|
||||
pub trait SocialHandler: Send + Sync {
|
||||
/// Short name used for logging etc.
|
||||
@@ -25,6 +32,3 @@ impl Clone for Box<dyn SocialHandler> {
|
||||
self.box_clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub use instagram::InstagramHandler;
|
||||
pub use youtube::YouTubeShortsHandler;
|
||||
|
||||
Reference in New Issue
Block a user