Skip to content

Commit

Permalink
Merge pull request #101 from php-http/feature/remove-deprecation-notice
Browse files Browse the repository at this point in the history
Remove internal deprecation notice
  • Loading branch information
sagikazarmark authored Oct 29, 2018
2 parents 741f226 + 3583ac0 commit 923ed1f
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 6 deletions.
6 changes: 5 additions & 1 deletion src/Encoding/CompressStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

namespace Http\Message\Encoding;

use Clue\StreamFilter as Filter;
use Psr\Http\Message\StreamInterface;

/**
Expand All @@ -21,7 +22,10 @@ public function __construct(StreamInterface $stream, $level = -1)
throw new \RuntimeException('The zlib extension must be enabled to use this stream');
}

parent::__construct($stream, ['window' => 15, 'level' => $level], ['window' => 15]);
parent::__construct($stream, ['window' => 15, 'level' => $level]);

// @deprecated will be removed in 2.0
$this->writeFilterCallback = Filter\fun($this->writeFilter(), ['window' => 15]);
}

/**
Expand Down
6 changes: 5 additions & 1 deletion src/Encoding/DecompressStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

namespace Http\Message\Encoding;

use Clue\StreamFilter as Filter;
use Psr\Http\Message\StreamInterface;

/**
Expand All @@ -21,7 +22,10 @@ public function __construct(StreamInterface $stream, $level = -1)
throw new \RuntimeException('The zlib extension must be enabled to use this stream');
}

parent::__construct($stream, ['window' => 15], ['window' => 15, 'level' => $level]);
parent::__construct($stream, ['window' => 15]);

// @deprecated will be removed in 2.0
$this->writeFilterCallback = Filter\fun($this->writeFilter(), ['window' => 15, 'level' => $level]);
}

/**
Expand Down
6 changes: 5 additions & 1 deletion src/Encoding/DeflateStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

namespace Http\Message\Encoding;

use Clue\StreamFilter as Filter;
use Psr\Http\Message\StreamInterface;

/**
Expand All @@ -17,7 +18,10 @@ class DeflateStream extends FilteredStream
*/
public function __construct(StreamInterface $stream, $level = -1)
{
parent::__construct($stream, ['window' => -15, 'level' => $level], ['window' => -15]);
parent::__construct($stream, ['window' => -15, 'level' => $level]);

// @deprecated will be removed in 2.0
$this->writeFilterCallback = Filter\fun($this->writeFilter(), ['window' => -15]);
}

/**
Expand Down
6 changes: 5 additions & 1 deletion src/Encoding/GzipDecodeStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

namespace Http\Message\Encoding;

use Clue\StreamFilter as Filter;
use Psr\Http\Message\StreamInterface;

/**
Expand All @@ -21,7 +22,10 @@ public function __construct(StreamInterface $stream, $level = -1)
throw new \RuntimeException('The zlib extension must be enabled to use this stream');
}

parent::__construct($stream, ['window' => 31], ['window' => 31, 'level' => $level]);
parent::__construct($stream, ['window' => 31]);

// @deprecated will be removed in 2.0
$this->writeFilterCallback = Filter\fun($this->writeFilter(), ['window' => 31, 'level' => $level]);
}

/**
Expand Down
6 changes: 5 additions & 1 deletion src/Encoding/GzipEncodeStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

namespace Http\Message\Encoding;

use Clue\StreamFilter as Filter;
use Psr\Http\Message\StreamInterface;

/**
Expand All @@ -21,7 +22,10 @@ public function __construct(StreamInterface $stream, $level = -1)
throw new \RuntimeException('The zlib extension must be enabled to use this stream');
}

parent::__construct($stream, ['window' => 31, 'level' => $level], ['window' => 31]);
parent::__construct($stream, ['window' => 31, 'level' => $level]);

// @deprecated will be removed in 2.0
$this->writeFilterCallback = Filter\fun($this->writeFilter(), ['window' => 31]);
}

/**
Expand Down
6 changes: 5 additions & 1 deletion src/Encoding/InflateStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

namespace Http\Message\Encoding;

use Clue\StreamFilter as Filter;
use Psr\Http\Message\StreamInterface;

/**
Expand All @@ -21,7 +22,10 @@ public function __construct(StreamInterface $stream, $level = -1)
throw new \RuntimeException('The zlib extension must be enabled to use this stream');
}

parent::__construct($stream, ['window' => -15], ['window' => -15, 'level' => $level]);
parent::__construct($stream, ['window' => -15]);

// @deprecated will be removed in 2.0
$this->writeFilterCallback = Filter\fun($this->writeFilter(), ['window' => -15, 'level' => $level]);
}

/**
Expand Down

0 comments on commit 923ed1f

Please sign in to comment.