blob: 455ed63f093a8fb2175a1d63cfd9f4210db849f1 (
plain)
1
2
3
4
5
6
7
8
|
import { type BushArgumentTypeCaster } from '#lib';
import { type Snowflake } from 'discord.js';
export const snowflake: BushArgumentTypeCaster = (_, phrase): Snowflake | null => {
if (!phrase) return null;
if (client.consts.regex.snowflake.test(phrase)) return phrase;
return null;
};
|