Fix syntax errors in PHP <5.4

This commit is contained in:
mark_story 2015-05-28 17:39:52 -04:00
parent b66c1ce53c
commit 65691836be
2 changed files with 3 additions and 3 deletions

View file

@ -229,7 +229,7 @@ class RequestHandlerComponent extends Component {
*/
public function convertXml($xml) {
try {
$xml = Xml::build($xml, ['readFile' => false]);
$xml = Xml::build($xml, array('readFile' => false));
if (isset($xml->data)) {
return Xml::toArray($xml->data);
}

View file

@ -175,7 +175,7 @@ class XmlTest extends CakeTestCase {
*/
public function testBuildFromFileWhenDisabled() {
$xml = CAKE . 'Test' . DS . 'Fixture' . DS . 'sample.xml';
$obj = Xml::build($xml, ['readFile' => false]);
$obj = Xml::build($xml, array('readFile' => false));
}
/**
@ -186,7 +186,7 @@ class XmlTest extends CakeTestCase {
*/
public function testBuildFromUrlWhenDisabled() {
$xml = 'http://www.google.com';
$obj = Xml::build($xml, ['readFile' => false]);
$obj = Xml::build($xml, array('readFile' => false));
}
/**