Conditions | 2 |
Paths | 2 |
Total Lines | 14 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 9 |
CRAP Score | 2 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
15 | 2 | public function filter($in, $out, &$consumed, $closing) |
|
16 | { |
||
17 | 2 | while ($bucket = stream_bucket_make_writeable($in)) { |
|
18 | 2 | $lenbucket = stream_bucket_new($this->stream, dechex($bucket->datalen)."\r\n"); |
|
|
|||
19 | 2 | stream_bucket_append($out, $lenbucket); |
|
20 | |||
21 | 2 | $consumed += $bucket->datalen; |
|
22 | 2 | stream_bucket_append($out, $bucket); |
|
23 | |||
24 | 2 | $lenbucket = stream_bucket_new($this->stream, "\r\n"); |
|
25 | 2 | stream_bucket_append($out, $lenbucket); |
|
26 | } |
||
27 | |||
28 | 2 | return PSFS_PASS_ON; |
|
29 | } |
||
31 |