3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-14 05:45:02 +00:00

Use commandTypeHelpers instead of baseTypeHelpers

This commit is contained in:
Dragory 2020-07-06 03:05:40 +03:00
parent c17fef6440
commit 3df57e3cb9
No known key found for this signature in database
GPG key ID: 5F387BA66DF8AAC1
5 changed files with 26 additions and 28 deletions

View file

@ -1,17 +1,17 @@
import { utilityCmd } from "../types";
import { baseTypeHelpers as t } from "knub";
import { commandTypeHelpers as ct } from "../../../commandTypes";
import { archiveSearch, displaySearch, SearchType } from "../search";
// Separate from BanSearchCmd to avoid a circular reference from ./search.ts
export const banSearchSignature = {
query: t.string({ catchAll: true }),
query: ct.string({ catchAll: true }),
page: t.number({ option: true, shortcut: "p" }),
sort: t.string({ option: true }),
"case-sensitive": t.switchOption({ shortcut: "cs" }),
export: t.switchOption({ shortcut: "e" }),
ids: t.switchOption(),
regex: t.switchOption({ shortcut: "re" }),
page: ct.number({ option: true, shortcut: "p" }),
sort: ct.string({ option: true }),
"case-sensitive": ct.switchOption({ shortcut: "cs" }),
export: ct.switchOption({ shortcut: "e" }),
ids: ct.switchOption(),
regex: ct.switchOption({ shortcut: "re" }),
};
export const BanSearchCmd = utilityCmd({