- improvement replaced some strlen($foo) > 3 calls by isset($foo[3])

This commit is contained in:
rodneyrehm
2011-10-01 18:47:56 +00:00
parent aff7c6a0ab
commit 655cbc94bc
9 changed files with 11 additions and 10 deletions
@@ -37,7 +37,7 @@ class Smarty_Internal_Compile_Private_Object_Block_Function extends Smarty_Inter
*/
public function compile($args, $compiler, $parameter, $tag, $method)
{
if (strlen($tag) < 5 || substr($tag, -5) != 'close') {
if (!isset($tag[5]) || substr($tag, -5) != 'close') {
// opening tag of block plugin
// check and get attributes
$_attr = $this->getAttributes($compiler, $args);