Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Enforce a maximum value when parsing unix timestamps (#981)
* UnixTimestampConverter should now obey a maximum value This change prevents an issue where the converter would be unable to handle obscenely large timestamp values - which are actually quite common on Discord. OptionalConverter had to be rewritten to support checking whether or not an InnerConverter returned an Optional. The perf impacts from this _shouldn't_ be too bad, as types without a custom parser (which should be the majority of Optionals in the lib) will bypass the type-check. * optimizations on OptionalConverter
- Loading branch information
Showing
2 changed files
with
21 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters