fix(validation): guard null comparison bounds in comparison builders
Passing a null bound to GreaterThan/LessThan/Between etc. called value.CompareTo(null), throwing NullReferenceException for non-null reference-type values. Short-circuit when the bound is null so the rule is satisfied instead of crashing.
This commit is contained in:
parent
ab9407085d
commit
68194d3cb3
4 changed files with 92 additions and 5 deletions
|
|
@ -51,6 +51,7 @@ To have a consistent experience across all packages, some public interfaces have
|
|||
|
||||
- **request.result:** Correct the namespace in the `Prelude` doc comment (`Geekeey.Extensions.Result` → `Geekeey.Request.Result`)
|
||||
- **request.result:** Fold `IsSuccess` into `Result<T>.GetHashCode` to avoid collisions between a failure and a success value whose hash is `0`
|
||||
- **request.validation:** Guard null comparison bounds in `GreaterThan`/`LessThan`/`Between` etc. so a `null` bound no longer throws (`NullReferenceException`)
|
||||
|
||||
### Removed
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue