We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4cc50c5 commit ca31786Copy full SHA for ca31786
Sources/OpenAPIRuntime/EventStreams/ServerSentEventsDecoding.swift
@@ -63,8 +63,8 @@ extension ServerSentEventsDeserializationSequence: AsyncSequence {
63
/// - Returns: `true` if the byte chunk should be forwarded, `false` if this byte chunk is the terminating sequence.
64
let predicate: (ArraySlice<UInt8>) -> Bool
65
66
- init(upstream: any AsyncIteratorProtocol, while predicate: @escaping ((ArraySlice<UInt8>) -> Bool)) {
67
- self.upstream = upstream as! UpstreamIterator
+ init(upstream: UpstreamIterator, while predicate: @escaping ((ArraySlice<UInt8>) -> Bool)) {
+ self.upstream = upstream
68
self.stateMachine = .init(while: predicate)
69
self.predicate = predicate
70
}
0 commit comments