Completed sender removal.

This commit is contained in:
Jeff Baskin 2025-03-30 11:47:36 -04:00
parent 80c2211333
commit 9bd46f2393

View File

@ -6,16 +6,6 @@ use uuid::Uuid;
pub enum Field {
Static(String),
Uuid(Uuid),
Tx(Sender<Message>),
}
impl Field {
pub fn to_sender(&self) -> Result<Sender<Message>, String> {
match self {
Field::Tx(sender) => Ok(sender.clone()),
_ => Err("not a sender field".to_string()),
}
}
}
impl From<String> for Field {
@ -49,7 +39,6 @@ impl fmt::Display for Field {
match self {
Field::Uuid(data) => write!(f, "{}", data),
Field::Static(data) => write!(f, "{}", data),
Field::Tx(_) => write!(f, "{}", "message sender"),
}
}
}