mirror of
https://github.com/wallabag/wallabag.git
synced 2024-10-31 22:28:54 +00:00
Factorize
This commit is contained in:
parent
7672a10776
commit
af8b3b649e
1 changed files with 3 additions and 10 deletions
|
@ -246,17 +246,10 @@ final class Tools
|
|||
$data[$k] = self::utf8ize($v);
|
||||
}
|
||||
}
|
||||
else if (is_string ($data))
|
||||
{
|
||||
if ('' == mb_detect_encoding($data))
|
||||
else if (is_string ($data) && '' == mb_detect_encoding($data))
|
||||
{
|
||||
return utf8_encode($data);
|
||||
}
|
||||
else
|
||||
{
|
||||
return $data;
|
||||
}
|
||||
}
|
||||
return $data;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue