Skip to content

Commit

Permalink
fix(FC2): change Category Type from String to Integer in Model
Browse files Browse the repository at this point in the history
- Change the type of `Category` from `string` to `int` in `ChannelData` class.

System.Text.Json.JsonException: The JSON value could not be converted to System.String. Path: $.data.channel_data.category | LineNumber: 0 | BytePositionInLine: 2859.
 ---> System.InvalidOperationException: Cannot get the value of a token type 'Number' as a string.

Signed-off-by: CHEN, CHUN <[email protected]>
  • Loading branch information
jim60105 committed Jan 8, 2025
1 parent a5f1ede commit 604c8f0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Models/FC2MemberData.cs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public class ChannelData
public int? Interval { get; set; }

[JsonPropertyName("category")]
public string Category { get; set; }
public int Category { get; set; }

[JsonPropertyName("category_name")]
public string CategoryName { get; set; }
Expand Down

0 comments on commit 604c8f0

Please sign in to comment.