Skip to content

Commit 3948542

Browse files
committed
use correct user id in timeout map
1 parent 30a2878 commit 3948542

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/events.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,8 @@ impl serenity::all::RawEventHandler for EventHandler {
9494
});
9595

9696
let mut timeout_map = TIMEOUT_MAP.lock().await;
97-
let timeout_count = timeout_map.entry(mention.id).or_insert(0);
97+
let timeout_count =
98+
timeout_map.entry(event.message.author.id).or_insert(0);
9899
*timeout_count += 1;
99100
let timeout_duration = match *timeout_count {
100101
1 | 2 => 30,

0 commit comments

Comments
 (0)