Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

indentation in templates

  • Loading branch information...
commit e1357ca8aa7f5ef85c12f686d6c9eeca3a240603 1 parent 70ac1c7
@dereuromark dereuromark authored
View
50 lib/Cake/Console/Templates/default/classes/controller.ctp
@@ -49,33 +49,33 @@ class <?php echo $controllerName; ?>Controller extends <?php echo $plugin; ?>App
<?php else:
- if (count($helpers)):
- echo "/**\n * Helpers\n *\n * @var array\n */\n";
- echo "\tpublic \$helpers = array(";
- for ($i = 0, $len = count($helpers); $i < $len; $i++):
- if ($i != $len - 1):
- echo "'" . Inflector::camelize($helpers[$i]) . "', ";
- else:
- echo "'" . Inflector::camelize($helpers[$i]) . "'";
- endif;
- endfor;
- echo ");\n\n";
- endif;
+ if (count($helpers)):
+ echo "/**\n * Helpers\n *\n * @var array\n */\n";
+ echo "\tpublic \$helpers = array(";
+ for ($i = 0, $len = count($helpers); $i < $len; $i++):
+ if ($i != $len - 1):
+ echo "'" . Inflector::camelize($helpers[$i]) . "', ";
+ else:
+ echo "'" . Inflector::camelize($helpers[$i]) . "'";
+ endif;
+ endfor;
+ echo ");\n\n";
+ endif;
- if (count($components)):
- echo "/**\n * Components\n *\n * @var array\n */\n";
- echo "\tpublic \$components = array(";
- for ($i = 0, $len = count($components); $i < $len; $i++):
- if ($i != $len - 1):
- echo "'" . Inflector::camelize($components[$i]) . "', ";
- else:
- echo "'" . Inflector::camelize($components[$i]) . "'";
- endif;
- endfor;
- echo ");\n\n";
- endif;
+ if (count($components)):
+ echo "/**\n * Components\n *\n * @var array\n */\n";
+ echo "\tpublic \$components = array(";
+ for ($i = 0, $len = count($components); $i < $len; $i++):
+ if ($i != $len - 1):
+ echo "'" . Inflector::camelize($components[$i]) . "', ";
+ else:
+ echo "'" . Inflector::camelize($components[$i]) . "'";
+ endif;
+ endfor;
+ echo ");\n\n";
+ endif;
- echo trim($actions) . "\n";
+ echo trim($actions) . "\n";
endif; ?>
}
View
6 lib/Cake/Console/Templates/default/classes/model.ctp
@@ -48,9 +48,9 @@ class <?php echo $name ?> extends <?php echo $plugin; ?>AppModel {
<?php endif;
if ($useTable && $useTable !== Inflector::tableize($name)):
- $table = "'$useTable'";
- echo "/**\n * Use table\n *\n * @var mixed False or table name\n */\n";
- echo "\tpublic \$useTable = $table;\n\n";
+ $table = "'$useTable'";
+ echo "/**\n * Use table\n *\n * @var mixed False or table name\n */\n";
+ echo "\tpublic \$useTable = $table;\n\n";
endif;
if ($primaryKey !== 'id'): ?>
Please sign in to comment.
Something went wrong with that request. Please try again.