Skip to content

Commit

Permalink
use GetValues method instead of GetNames (RicoSuter#4828)
Browse files Browse the repository at this point in the history
  • Loading branch information
testfirstcoder authored and lahma committed Jun 13, 2024
1 parent 9915648 commit ef3fcda
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -73,9 +73,8 @@ public OpenApiToTypeScriptClientCommand Command
.ToArray();

/// <summary>Gets the list of date time types.</summary>
public TypeScriptDateTimeType[] DateTimeTypes { get; } = Enum.GetNames(typeof(TypeScriptDateTimeType))
.Select(t => (TypeScriptDateTimeType)Enum.Parse(typeof(TypeScriptDateTimeType), t))
.ToArray();
public TypeScriptDateTimeType[] DateTimeTypes { get; } =
(TypeScriptDateTimeType[])Enum.GetValues(typeof(TypeScriptDateTimeType));

/// <summary>Gets the list of null values.</summary>
public TypeScriptNullValue[] NullValues { get; } = Enum.GetNames(typeof(TypeScriptNullValue))
Expand Down

0 comments on commit ef3fcda

Please sign in to comment.