style: 强类型大法
This commit is contained in:
1 parent
76501bae34
commit
70945cf2d8
191 files changed
+923
-806
No files matched your search
@@ -1,10 +1,10 @@
|
||||
import { OneBotAction } from '@/onebot/action/OneBotAction';
|
||||
import { ActionName } from '@/onebot/action/router';
|
||||
|
||||
export class GetGuildList extends OneBotAction<null, null> {
|
||||
actionName = ActionName.GetGuildList;
|
||||
export class GetGuildList extends OneBotAction<void, void> {
|
||||
override actionName = ActionName.GetGuildList;
|
||||
|
||||
async _handle(payload: null): Promise<null> {
|
||||
return null;
|
||||
async _handle(): Promise<void> {
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -1,10 +1,10 @@
|
||||
import { OneBotAction } from '@/onebot/action/OneBotAction';
|
||||
import { ActionName } from '@/onebot/action/router';
|
||||
|
||||
export class GetGuildProfile extends OneBotAction<null, null> {
|
||||
actionName = ActionName.GetGuildProfile;
|
||||
export class GetGuildProfile extends OneBotAction<void, void> {
|
||||
override actionName = ActionName.GetGuildProfile;
|
||||
|
||||
async _handle(payload: null): Promise<null> {
|
||||
return null;
|
||||
async _handle(): Promise<void> {
|
||||
return;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user