Added method to set topic of a channel.
This commit is contained in:
parent
b473a29dc0
commit
0ad2411c14
1 changed files with 4 additions and 0 deletions
|
@ -44,6 +44,10 @@ impl<'a> Bot<'a> {
|
||||||
send(&self.conn, Message::new(None, "JOIN", [chan.as_slice()]))
|
send(&self.conn, Message::new(None, "JOIN", [chan.as_slice()]))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn send_topic(&self, chan: &str, topic: &str) -> IoResult<()> {
|
||||||
|
send(&self.conn, Message::new(None, "TOPIC", [chan.as_slice(), topic.as_slice()]))
|
||||||
|
}
|
||||||
|
|
||||||
pub fn send_invite(&self, person: &str, chan: &str) -> IoResult<()> {
|
pub fn send_invite(&self, person: &str, chan: &str) -> IoResult<()> {
|
||||||
send(&self.conn, Message::new(None, "INVITE", [person.as_slice(), chan.as_slice()]))
|
send(&self.conn, Message::new(None, "INVITE", [person.as_slice(), chan.as_slice()]))
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue