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 707cff0 commit 372bf28Copy full SHA for 372bf28
src/Core/Util.php
@@ -10,6 +10,11 @@
10
use Psr\Http\Message\StreamInterface;
11
use Psr\Http\Message\UriInterface;
12
13
+/**
14
+ * @phpstan-type SSEvent = array{
15
+ * event?: string|null, data?: string|null, id?: string|null, retry?: int|null
16
+ * }
17
+ */
18
final class Util
19
{
20
public const BUF_SIZE = 8192;
@@ -239,11 +244,7 @@ public static function decodeLines(\Iterator $stream): \Iterator
239
244
/**
240
245
* @param \Iterator<string> $lines
241
246
*
242
- * @return \Generator<
243
- * array{
- * event?: string|null, data?: string|null, id?: string|null, retry?: int|null
- * },
- * >
247
+ * @return \Generator<SSEvent>
248
*/
249
public static function decodeSSE(\Iterator $lines): \Generator
250
0 commit comments