diff --git a/src/state.rs b/src/state.rs index 136c865..f5dcd5b 100644 --- a/src/state.rs +++ b/src/state.rs @@ -68,6 +68,35 @@ impl RircdState { //> who needs a daemon that does nothing and where nothing can be configured to be done + ////////////////////////////////////////////// + // + // T O D O + // + // Add a mechanism to on received + // Event::Message's to only send + // them to ALL other endpoints + // except to that where it originated + // from TO PREVENT ECHOING + // + // Eg over a .send_from field + // eg: + // + // match event.kind { + // Message(msg) => { + // for ep_rc in endpoints_receivers { + // if ep_rc != msg.from { + // ep_rc.send(msg) + // } + // } + // }, + // } + // + // ^^^ FOR THIS maybe having a wrapper around (R) from + // the endpoint_receivers[R] is required. That contains + // a ref to the endpoint or sth ... idk + // + ////////////////////////////////////////////// + loop { println!("received event"); tokio::select! {