mirror of
https://github.com/sern-handler/handler
synced 2026-06-28 02:32:15 +00:00
type alias
This commit is contained in:
@@ -3,6 +3,7 @@ import type {
|
||||
CommandModule,
|
||||
CommandModuleDefs,
|
||||
Module,
|
||||
OnError,
|
||||
} from '../../types/core-modules';
|
||||
import { CommandType } from '../structures';
|
||||
|
||||
@@ -12,8 +13,8 @@ interface MetadataAccess {
|
||||
}
|
||||
|
||||
interface OnErrorAccess {
|
||||
getErrorCallback(m: Module): Record<string,Function>|undefined;
|
||||
setErrorCallback(m: Module, c: Record<string,Function>): void;
|
||||
getErrorCallback(m: Module): OnError;
|
||||
setErrorCallback(m: Module, c: NonNullable<OnError>): void;
|
||||
}
|
||||
/**
|
||||
* @since 2.0.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { CommandMeta, Module } from '../../types/core-modules';
|
||||
import type { CommandMeta, Module, OnError } from '../../types/core-modules';
|
||||
|
||||
/**
|
||||
* Represents a core module store that stores IDs mapped to file paths.
|
||||
@@ -6,5 +6,5 @@ import type { CommandMeta, Module } from '../../types/core-modules';
|
||||
export interface CoreModuleStore {
|
||||
commands: Map<string, string>;
|
||||
metadata: WeakMap<Module, CommandMeta>;
|
||||
onError: WeakMap<Module, Record<string,Function>>;
|
||||
onError: WeakMap<Module, NonNullable<OnError>>;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user