mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-31 09:06:17 +00:00
Removing dead code, and adding another deprecation warning.
This commit is contained in:
parent
1cb0e413be
commit
1c417ac2fd
1 changed files with 1 additions and 8 deletions
|
@ -92,14 +92,6 @@ class RequestHandlerComponent extends Component {
|
||||||
*/
|
*/
|
||||||
function __construct(ComponentCollection $collection, $settings = array()) {
|
function __construct(ComponentCollection $collection, $settings = array()) {
|
||||||
$this->addInputType('xml', array(array($this, '_convertXml')));
|
$this->addInputType('xml', array(array($this, '_convertXml')));
|
||||||
$this->__acceptTypes = explode(',', env('HTTP_ACCEPT'));
|
|
||||||
|
|
||||||
foreach ($this->__acceptTypes as $i => $type) {
|
|
||||||
if (strpos($type, ';')) {
|
|
||||||
$type = explode(';', $type);
|
|
||||||
$this->__acceptTypes[$i] = $type[0];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
parent::__construct($collection, $settings);
|
parent::__construct($collection, $settings);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -362,6 +354,7 @@ class RequestHandlerComponent extends Component {
|
||||||
* @param mixed $type The Content-type or array of Content-types assigned to the name,
|
* @param mixed $type The Content-type or array of Content-types assigned to the name,
|
||||||
* i.e. "text/html", or "application/xml"
|
* i.e. "text/html", or "application/xml"
|
||||||
* @return void
|
* @return void
|
||||||
|
* @deprecated use `$this->response->type()` instead.
|
||||||
*/
|
*/
|
||||||
public function setContent($name, $type = null) {
|
public function setContent($name, $type = null) {
|
||||||
$this->response->type(array($name => $type));
|
$this->response->type(array($name => $type));
|
||||||
|
|
Loading…
Add table
Reference in a new issue