Merge pull request #2873 from sam-at-github/requesthandlercomponent-reuse-a-var

One liner. Dont call function parseAccept() twice in RequestHandlerCompo...
This commit is contained in:
Mark Story 2014-02-20 10:03:46 -05:00
commit 2289521e30

View file

@ -159,7 +159,7 @@ class RequestHandlerComponent extends Component {
return;
}
$accepts = $this->response->mapType($this->request->parseAccept());
$accepts = $this->response->mapType($accept);
$preferedTypes = current($accepts);
if (array_intersect($preferedTypes, array('html', 'xhtml'))) {
return null;