Skip to content

Commit

Permalink
Ignore create channel on winston added
Browse files Browse the repository at this point in the history
  • Loading branch information
gabber235 committed Oct 17, 2024
1 parent f3e194c commit c7083b9
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions discord_bot/src/discord/thread_intake.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,11 @@ pub struct ThreadIntakeHandler;
#[async_trait]
impl EventHandler for ThreadIntakeHandler {
async fn thread_create(&self, ctx: Context, mut thread: GuildChannel) {
// When tags are already applied, the bot is added later not on creation. Like at closing
// the channel.
if !thread.applied_tags.is_empty() {
return;
}
let Some(parent) = thread.parent_id else {
return;
};
Expand Down

0 comments on commit c7083b9

Please sign in to comment.