mirror of
https://github.com/sern-handler/handler
synced 2026-06-06 01:16:55 +00:00
fix typings
This commit is contained in:
@@ -14,16 +14,19 @@ import * as assert from 'assert';
|
||||
import type { ReplyOptions } from '../../types/utility';
|
||||
import { fmt } from '../functions'
|
||||
|
||||
type ShitType = ChatInputCommandInteraction['options']
|
||||
|
||||
/**
|
||||
* @since 1.0.0
|
||||
* Provides values shared between
|
||||
* Message and ChatInputCommandInteraction
|
||||
*/
|
||||
export class Context extends CoreContext<Message, ChatInputCommandInteraction> {
|
||||
|
||||
get options() {
|
||||
return this.interaction.options;
|
||||
}
|
||||
args(type: 'message') : string[]
|
||||
args(type: 'interaction') : ShitType
|
||||
//TODO
|
||||
args(type: 'message'|'interaction') {
|
||||
switch(type) {
|
||||
|
||||
@@ -24,7 +24,7 @@ import { Awaitable, SernEventsMapping } from './utility';
|
||||
export type SDT = {
|
||||
state: Record<string,unknown>;
|
||||
deps: Dependencies;
|
||||
type: 'slash' | 'text',
|
||||
type: CommandType,
|
||||
params?: string
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user