Skip to content

Commit

Permalink
Check OTL data count against NULL (Closes #562)
Browse files Browse the repository at this point in the history
  • Loading branch information
finwe committed Nov 30, 2017
1 parent 0c392eb commit 51171cb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Otl.php
Original file line number Diff line number Diff line change
Expand Up @@ -5785,7 +5785,7 @@ public function replaceSpace(&$txt, &$cOTLdata)

public function trimOTLdata(&$cOTLdata, $Left = true, $Right = true)
{
$len = count($cOTLdata['char_data']);
$len = $cOTLdata['char_data'] === null ? 0 : count($cOTLdata['char_data']);
$nLeft = 0;
$nRight = 0;
for ($i = 0; $i < $len; $i++) {
Expand Down

0 comments on commit 51171cb

Please sign in to comment.