Improve code style

This commit is contained in:
Val Bancer 2018-11-17 20:55:42 +01:00
parent 261a99c0e3
commit 509accc421
2 changed files with 4 additions and 5 deletions

View file

@ -271,9 +271,11 @@ class RequestHandlerComponent extends Component {
}
if (!empty($status)) {
$statusCode = $this->response->httpCodes($status);
if (is_array($statusCode)) {
$code = key($statusCode);
$this->response->statusCode($code);
}
}
$this->response->body($this->requestAction($url, array('return', 'bare' => false)));
$this->response->send();
$this->_stop();

View file

@ -1318,9 +1318,6 @@ class CakeResponse {
continue;
}
$original = $domain;
if (strpos($domain, '://') === false) {
$preg = ($requestIsSSL ? 'https://' : 'http://') . $domain;
}
$preg = '@' . str_replace('*', '.*', $domain) . '@';
$result[] = compact('original', 'preg');
}