diff options
Diffstat (limited to 'lib/arguments/duration.ts')
-rw-r--r-- | lib/arguments/duration.ts | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/arguments/duration.ts b/lib/arguments/duration.ts new file mode 100644 index 0000000..09dd3d5 --- /dev/null +++ b/lib/arguments/duration.ts @@ -0,0 +1,5 @@ +import { parseDuration, type BushArgumentTypeCaster } from '#lib'; + +export const duration: BushArgumentTypeCaster<number | null> = (_, phrase) => { + return parseDuration(phrase).duration; +}; |