more tags
This commit is contained in:
parent
2c0e5170f4
commit
97cc215f05
@ -28,6 +28,7 @@ impl Envelope {
|
||||
|
||||
match &event {
|
||||
&Event::Message { ref message } => {
|
||||
tags.insert(String::from("type:message"));
|
||||
tags.insert(format!("user:{:}", message.author.name));
|
||||
match message.channel {
|
||||
Some(ref channel) => {
|
||||
@ -37,16 +38,20 @@ impl Envelope {
|
||||
}
|
||||
},
|
||||
&Event::SelfJoin { ref channel } => {
|
||||
tags.insert(String::from("type:selfjoin"));
|
||||
tags.insert(format!("channel:{:}", channel.name));
|
||||
},
|
||||
&Event::SelfQuit { ref channel } => {
|
||||
tags.insert(String::from("type:selfquit"));
|
||||
tags.insert(format!("channel:{:}", channel.name));
|
||||
},
|
||||
&Event::UserJoin { ref channel, ref user } => {
|
||||
tags.insert(String::from("type:userjoin"));
|
||||
tags.insert(format!("channel:{:}", channel.name));
|
||||
tags.insert(format!("user:{:}", user.name));
|
||||
},
|
||||
&Event::UserQuit { ref channel, ref user } => {
|
||||
tags.insert(String::from("type:userquit"));
|
||||
tags.insert(format!("channel:{:}", channel.name));
|
||||
tags.insert(format!("user:{:}", user.name));
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user