Commit 2eeea109 by pupi1985

Avoid calling qa_strlen twice

parent 49f054ce
...@@ -512,7 +512,9 @@ ...@@ -512,7 +512,9 @@
else else
$word=array_shift($words); $word=array_shift($words);
if (qa_strlen($word)>$remaining) $wordLength = qa_strlen($word);
if ($wordLength>$remaining)
break; break;
if ($tosuffix) if ($tosuffix)
...@@ -520,7 +522,7 @@ ...@@ -520,7 +522,7 @@
else else
$prefix.=$word; $prefix.=$word;
$remaining-=qa_strlen($word); $remaining-=$wordLength;
} }
$string=$prefix.' ... '.$suffix; $string=$prefix.' ... '.$suffix;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment