mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-05-10 04:25:01 +00:00
10 lines
350 B
TypeScript
10 lines
350 B
TypeScript
import { GuildPluginData } from "knub";
|
|
import { ModActionsEvents, ModActionsPluginType } from "../types";
|
|
|
|
export function onModActionsEvent<TEvent extends keyof ModActionsEvents>(
|
|
pluginData: GuildPluginData<ModActionsPluginType>,
|
|
event: TEvent,
|
|
listener: ModActionsEvents[TEvent],
|
|
) {
|
|
return pluginData.state.events.on(event, listener);
|
|
}
|