Be forward compatible to PHP 7's "Uniform Variable Syntax"

https://wiki.php.net/rfc/uniform_variable_syntax
This commit is contained in:
Marc Würth 2014-08-11 01:33:25 +02:00
parent d114fa1431
commit 120bd37ffa

View file

@ -248,10 +248,10 @@ class ControllerTask extends BakeTask {
);
foreach ($properties as $var => $title) {
if (count($$var)) {
if (count(${$var})) {
$output = '';
$length = count($$var);
foreach ($$var as $i => $propElement) {
$length = count(${$var});
foreach (${$var} as $i => $propElement) {
if ($i != $length - 1) {
$output .= ucfirst($propElement) . ', ';
} else {