Skip to content

Commit

Permalink
Merge pull request #14 from stevenay/master
Browse files Browse the repository at this point in the history
Fix PHP zero "0" string error
  • Loading branch information
sffc authored Jul 7, 2018
2 parents 41d2591 + 17d9bd1 commit 820c3d0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion clients/php/src/ZawgyiUnicodeMarkovModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ public function predict(string $input, bool $verbose = false): float

public static function ord_utf8($c)
{
if (empty($c))
if (is_null($c) || $c === "")
return;

$u32 = mb_convert_encoding($c, "UTF-32BE");
Expand Down

0 comments on commit 820c3d0

Please sign in to comment.