refactor(events): don't return when no Owners
This commit is contained in:
parent
74a810b956
commit
97961b0a49
@ -48,7 +48,10 @@ pub async fn handle_event(client: Client, event: Event, state: State) -> anyhow:
|
||||
}
|
||||
|
||||
if is_whisper
|
||||
&& globals.get::<Vec<String>>("Owners")?.contains(sender)
|
||||
&& globals
|
||||
.get::<Vec<String>>("Owners")
|
||||
.unwrap_or_default()
|
||||
.contains(sender)
|
||||
&& let Err(error) = state.commands.execute(
|
||||
content.clone(),
|
||||
CommandSource {
|
||||
|
Loading…
x
Reference in New Issue
Block a user