Add unit test to check that AnyRequest handles missing parameters (#24)

* Add unit test to check that AnyRequest handles missing parameters

* Conform Value to NotRequired

* Add test for decoding AnyRequest with empty parameters

---------

Co-authored-by: Mattt Zmuda <mattt@loopwork.com>
This commit is contained in:
Adam Wulf 2025-03-19 07:41:50 -05:00 • committed by GitHub
commit da97a3db3c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -11,6 +11,12 @@ public struct Empty: NotRequired, Hashable, Codable, Sendable {
public init() {}
}
extension Value: NotRequired {
public init() {
self = .null
}
}
// MARK: -
/// A method that can be used to send requests and receive responses.