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 e6c3ab5 commit fdac6a3Copy full SHA for fdac6a3
README.md
@@ -107,6 +107,9 @@ public function callback($ch, $data) {
107
// 0、把上次缓冲区内数据拼接上本次的data
108
$buffer = $this->data_buffer.$data;
109
110
+ //拼接完之后,要把缓冲字符串清空
111
+ $this->data_buffer = '';
112
+
113
// 1、把所有的 'data: {' 替换为 '{' ,'data: [' 换成 '['
114
$buffer = str_replace('data: {', '{', $buffer);
115
$buffer = str_replace('data: [', '[', $buffer);
0 commit comments