We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 82902c0 commit 2acd41bCopy full SHA for 2acd41b
1 file changed
backend/src/plugin/core/public/command.ts
@@ -183,11 +183,11 @@ interface DurationOption extends BaseOption {
183
type: OptionType.Duration;
184
}
185
186
-type OptionValue<F extends Option> = F["array"] extends true
187
- ? ArrayValue<OptionTypeValue<F["type"]>, F["required"]>
188
- : F["required"] extends true
189
- ? NullableValue<OptionTypeValue<F["type"]>, F["required"]>
190
- : OptionTypeValue<F["type"]> | null;
+type OptionValue<TOpt extends Option> = TOpt["array"] extends true
+ ? ArrayValue<OptionTypeValue<TOpt["type"]>, TOpt["required"]>
+ : TOpt["required"] extends true
+ ? NullableValue<OptionTypeValue<TOpt["type"]>, TOpt["required"]>
+ : OptionTypeValue<TOpt["type"]> | null;
191
192
type ArrayValue<
193
TOpt,
0 commit comments