chore: OneBotApi
This commit is contained in:
1 parent
7842cd0bc0
commit
8a4add257f
111 files changed
+4493
No files matched your search
@@ -0,0 +1,17 @@
|
||||
import { log } from '@/common/utils/log';
|
||||
import BaseAction from '../BaseAction';
|
||||
import { ActionName } from '../types';
|
||||
import { QuickAction, QuickActionEvent, handleQuickOperation } from '@/onebot11/server/postOB11Event';
|
||||
|
||||
interface Payload{
|
||||
context: QuickActionEvent,
|
||||
operation: QuickAction
|
||||
}
|
||||
|
||||
export class GoCQHTTPHandleQuickAction extends BaseAction<Payload, null>{
|
||||
actionName = ActionName.GoCQHTTP_HandleQuickAction;
|
||||
protected async _handle(payload: Payload): Promise<null> {
|
||||
handleQuickOperation(payload.context, payload.operation).then().catch(log);
|
||||
return null;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user