mirror of
https://github.com/e107inc/e107.git
synced 2025-07-31 11:50:30 +02:00
Emoticon parser PHP warning removal Issue #1633
This commit is contained in:
@@ -4617,11 +4617,11 @@ return $html;
|
|||||||
|
|
||||||
class e_emotefilter
|
class e_emotefilter
|
||||||
{
|
{
|
||||||
private $search;
|
private $search = array();
|
||||||
private $replace;
|
private $replace = array();
|
||||||
public $emotes;
|
public $emotes;
|
||||||
private $singleSearch;
|
private $singleSearch = array();
|
||||||
private $singleReplace;
|
private $singleReplace = array();
|
||||||
|
|
||||||
function __construct()
|
function __construct()
|
||||||
{
|
{
|
||||||
@@ -4733,7 +4733,7 @@ class e_emotefilter
|
|||||||
return '';
|
return '';
|
||||||
}
|
}
|
||||||
|
|
||||||
if((strlen($text) < 12) && in_array($text, $this->singleSearch)) // just one emoticon with no space, line-break or html tags around it.
|
if(!empty($this->singleSearch) && (strlen($text) < 12) && in_array($text, $this->singleSearch)) // just one emoticon with no space, line-break or html tags around it.
|
||||||
{
|
{
|
||||||
return str_replace($this->singleSearch,$this->singleReplace,$text);
|
return str_replace($this->singleSearch,$this->singleReplace,$text);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user