refactor: remove ts-results-es (#366)

* remove tsresultses

* remove test since it uses external api

* opt in for simpler

* add more debug information

Signed-off-by: Jacob Nguyen <76754747+jacoobes@users.noreply.github.com>

* add more debug information

Signed-off-by: Jacob Nguyen <76754747+jacoobes@users.noreply.github.com>

* clean up if else

---------

Signed-off-by: Jacob Nguyen <76754747+jacoobes@users.noreply.github.com>
This commit is contained in:
Jacob Nguyen
2024-08-11 11:07:44 -05:00
committed by GitHub
parent 3755b95b1a
commit 61e82fdc7b
10 changed files with 77 additions and 101 deletions

View File

@@ -11,7 +11,6 @@
* Plugins are reminiscent of middleware in express.
*/
import type { Result } from 'ts-results-es';
import type {
Module,
Processed,
@@ -31,6 +30,7 @@ import type {
UserContextMenuCommandInteraction,
UserSelectMenuInteraction,
} from 'discord.js';
import { Result } from '../core/structures/result';
export type PluginResult = Awaitable<Result<Record<string,unknown>|undefined, string|undefined>>;
export interface InitArgs<T extends Processed<Module> = Processed<Module>> {

View File

@@ -1,6 +1,6 @@
import type { InteractionReplyOptions, MessageReplyOptions } from 'discord.js';
import type { Module } from './core-modules';
import type { Result } from 'ts-results-es';
import type { Result } from '../core/structures/result';
export type Awaitable<T> = PromiseLike<T> | T;