Fix deadlock when two users use selector at the same time
This commit is contained in:
parent
8ed0e9079b
commit
a2dd37118a
|
@ -153,6 +153,7 @@ impl EventHandler for Handler {
|
|||
.run(ctx.clone(), self.database.clone())
|
||||
.await
|
||||
} else {
|
||||
drop(users_selector);
|
||||
Err(CommandExecutionError::SelectorError(
|
||||
"User has already a selector running".to_string(),
|
||||
))
|
||||
|
@ -169,6 +170,7 @@ impl EventHandler for Handler {
|
|||
.run(ctx.clone(), self.database.clone())
|
||||
.await
|
||||
} else {
|
||||
drop(users_selector);
|
||||
Err(CommandExecutionError::SelectorError(
|
||||
"User has already a selector running".to_string(),
|
||||
))
|
||||
|
|
Loading…
Reference in a new issue