From 09bb83e14955dbb82ff0a2417b936ec406bff85f Mon Sep 17 00:00:00 2001 From: William Durand Date: Tue, 27 Oct 2015 09:23:44 +0100 Subject: [PATCH] Restore 5.3 compat (implicit) Implicit means: it's a best effort approach but there is no guarantee that this bundle will continue to work well with PHP < 5.4 --- Parser/FormTypeParser.php | 4 ++-- composer.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Parser/FormTypeParser.php b/Parser/FormTypeParser.php index aec513b55..8c17d28b0 100644 --- a/Parser/FormTypeParser.php +++ b/Parser/FormTypeParser.php @@ -268,7 +268,7 @@ private function parseForm($form) } else { // TODO: fixme // does not work since: https://github.com/symfony/symfony/commit/03efce1b568379eac21d880e427090e43035f505 - $choices = []; + $choices = array(); } if (is_array($choices) && count($choices)) { @@ -306,7 +306,7 @@ private function getTypeInstance($type) return $refl->newInstance(); } - private function createForm($item, $data = null, array $options = []) + private function createForm($item, $data = null, array $options = array()) { if ($this->implementsType($item)) { $type = $this->getTypeInstance($item); diff --git a/composer.json b/composer.json index b90664f76..46e94c2ee 100644 --- a/composer.json +++ b/composer.json @@ -15,7 +15,7 @@ } ], "require": { - "php": ">=5.4", + "php": ">=5.3", "symfony/twig-bundle": "~2.3", "symfony/framework-bundle": "~2.3", "symfony/console": "~2.3",