diff options
| author | uwetews <uwe.tews@googlemail.com> | 2016-02-09 01:27:15 +0100 |
|---|---|---|
| committer | uwetews <uwe.tews@googlemail.com> | 2016-02-09 01:27:15 +0100 |
| commit | b04486a091558a2b1280e3ee7fb90758e9a32230 (patch) | |
| tree | ddb15a12dba78e6873a348acd25f872429e210d2 /libs/plugins/modifiercompiler.wordwrap.php | |
| parent | c59ca44b9ff62a7f54e30409514834a8529780ca (diff) | |
| download | smarty-b04486a091558a2b1280e3ee7fb90758e9a32230.tar.gz smarty-b04486a091558a2b1280e3ee7fb90758e9a32230.tar.bz2 smarty-b04486a091558a2b1280e3ee7fb90758e9a32230.zip | |
- reformat all code for unique style
Diffstat (limited to 'libs/plugins/modifiercompiler.wordwrap.php')
| -rw-r--r-- | libs/plugins/modifiercompiler.wordwrap.php | 26 |
1 files changed, 15 insertions, 11 deletions
diff --git a/libs/plugins/modifiercompiler.wordwrap.php b/libs/plugins/modifiercompiler.wordwrap.php index 6bb63247..91849738 100644 --- a/libs/plugins/modifiercompiler.wordwrap.php +++ b/libs/plugins/modifiercompiler.wordwrap.php @@ -22,26 +22,30 @@ */ function smarty_modifiercompiler_wordwrap($params, $compiler) { - if (!isset($params[1])) { - $params[1] = 80; + if (!isset($params[ 1 ])) { + $params[ 1 ] = 80; } - if (!isset($params[2])) { - $params[2] = '"\n"'; + if (!isset($params[ 2 ])) { + $params[ 2 ] = '"\n"'; } - if (!isset($params[3])) { - $params[3] = 'false'; + if (!isset($params[ 3 ])) { + $params[ 3 ] = 'false'; } $function = 'wordwrap'; if (Smarty::$_MBSTRING) { if ($compiler->template->caching && ($compiler->tag_nocache | $compiler->nocache)) { - $compiler->parent_compiler->template->compiled->required_plugins['nocache']['wordwrap']['modifier']['file'] = SMARTY_PLUGINS_DIR . 'shared.mb_wordwrap.php'; - $compiler->template->required_plugins['nocache']['wordwrap']['modifier']['function'] = 'smarty_mb_wordwrap'; + $compiler->parent_compiler->template->compiled->required_plugins[ 'nocache' ][ 'wordwrap' ][ 'modifier' ][ 'file' ] = + SMARTY_PLUGINS_DIR . 'shared.mb_wordwrap.php'; + $compiler->template->required_plugins[ 'nocache' ][ 'wordwrap' ][ 'modifier' ][ 'function' ] = + 'smarty_mb_wordwrap'; } else { - $compiler->parent_compiler->template->compiled->required_plugins['compiled']['wordwrap']['modifier']['file'] = SMARTY_PLUGINS_DIR . 'shared.mb_wordwrap.php'; - $compiler->parent_compiler->template->compiled->required_plugins['compiled']['wordwrap']['modifier']['function'] = 'smarty_mb_wordwrap'; + $compiler->parent_compiler->template->compiled->required_plugins[ 'compiled' ][ 'wordwrap' ][ 'modifier' ][ 'file' ] = + SMARTY_PLUGINS_DIR . 'shared.mb_wordwrap.php'; + $compiler->parent_compiler->template->compiled->required_plugins[ 'compiled' ][ 'wordwrap' ][ 'modifier' ][ 'function' ] = + 'smarty_mb_wordwrap'; } $function = 'smarty_mb_wordwrap'; } - return $function . '(' . $params[0] . ',' . $params[1] . ',' . $params[2] . ',' . $params[3] . ')'; + return $function . '(' . $params[ 0 ] . ',' . $params[ 1 ] . ',' . $params[ 2 ] . ',' . $params[ 3 ] . ')'; } |
