From 212177c9c435488d17deb340137fef3684dce30d Mon Sep 17 00:00:00 2001 From: some1chan <31833556+some1chan@users.noreply.github.com> Date: Wed, 31 Aug 2022 06:41:44 +0000 Subject: [PATCH] fix: include BaseDiscordMenuFlow types --- .../BaseDiscordMenuFlowSelectMenuHandleOptions.ts | 10 ++++++++++ .../BaseDiscordMenuFlowSelectMenuReturnOptions.ts | 6 ++++++ 2 files changed, 16 insertions(+) create mode 100644 packages/core/src/interfaces/BaseDiscordMenuFlowSelectMenuHandleOptions.ts create mode 100644 packages/core/src/interfaces/BaseDiscordMenuFlowSelectMenuReturnOptions.ts diff --git a/packages/core/src/interfaces/BaseDiscordMenuFlowSelectMenuHandleOptions.ts b/packages/core/src/interfaces/BaseDiscordMenuFlowSelectMenuHandleOptions.ts new file mode 100644 index 0000000..2c72853 --- /dev/null +++ b/packages/core/src/interfaces/BaseDiscordMenuFlowSelectMenuHandleOptions.ts @@ -0,0 +1,10 @@ +export interface BaseDiscordMenuFlowSelectMenuHandleOptions { + /** + * Should this function throw a PageNotFoundError, + * if a page wasn't found? If true, the default + * error message will not send, and should be handled + * by the bot developer. + * @default false + */ + returnPageNotFoundError?: boolean; +} diff --git a/packages/core/src/interfaces/BaseDiscordMenuFlowSelectMenuReturnOptions.ts b/packages/core/src/interfaces/BaseDiscordMenuFlowSelectMenuReturnOptions.ts new file mode 100644 index 0000000..b34c4fc --- /dev/null +++ b/packages/core/src/interfaces/BaseDiscordMenuFlowSelectMenuReturnOptions.ts @@ -0,0 +1,6 @@ +import { PageNotFoundError } from "../structures/errors/PageNotFoundError"; + +export interface BaseDiscordMenuFlowSelectMenuReturnOptions { + pageNotFoundError?: PageNotFoundError; + passthrough?: boolean; +} \ No newline at end of file