Remora / Remora.Discord

A data-oriented C# Discord library, focused on high-performance concurrency and robust design.
GNU Lesser General Public License v3.0
243 stars 46 forks source link

Fix convert discrepancies between partial and non-partial type #307

Closed MazeXP closed 1 year ago

MazeXP commented 1 year ago

In cases when a PartialChannel object has a default_thread_rate_limit_per_user property provided, the deserialization would fail as it was trying to convert the TimeSpan using the default TimeSpanConverter (expects string) instead of the UnitTimeSpanConverter (expects double/integer).

In addition I found a similiar discrepancy between IAttachment and IPartialAttachment (duration_secs), so I got them also on par.