aboutsummaryrefslogtreecommitdiff
path: root/src/arguments/contentWithDuration.ts
blob: 8dd7621c7f4db1c681b8c7faf39752ff6618c37c (plain)
1
2
3
4
5
6
7
8
9
import { BushArgumentTypeCaster } from '../lib/extensions/discord-akairo/BushArgumentTypeCaster';
import { BushMessage } from '../lib/extensions/discord.js/BushMessage';

export const contentWithDurationTypeCaster: BushArgumentTypeCaster = async (
	_message: BushMessage,
	phrase
): Promise<{ duration: number; contentWithoutTime: string }> => {
	return client.util.parseDuration(phrase);
};