aboutsummaryrefslogtreecommitdiff
path: root/lib/arguments/contentWithDuration.ts
diff options
context:
space:
mode:
Diffstat (limited to 'lib/arguments/contentWithDuration.ts')
-rw-r--r--lib/arguments/contentWithDuration.ts5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/arguments/contentWithDuration.ts b/lib/arguments/contentWithDuration.ts
new file mode 100644
index 0000000..0efba39
--- /dev/null
+++ b/lib/arguments/contentWithDuration.ts
@@ -0,0 +1,5 @@
+import { parseDuration, type BushArgumentTypeCaster, type ParsedDuration } from '#lib';
+
+export const contentWithDuration: BushArgumentTypeCaster<Promise<ParsedDuration>> = async (_, phrase) => {
+ return parseDuration(phrase);
+};