Prevent some notices and process if $CFG->emoticons is not set or empty. MDL-12414 ; merged from 19_STABLE

This commit is contained in:
stronk7 2008-05-11 23:34:29 +00:00
parent dd1e295528
commit 183a13c294

View file

@ -2032,8 +2032,13 @@ function cleanAttributes2($htmlArray){
* @return string
*/
function replace_smilies(&$text) {
///
global $CFG;
if (empty($CFG->emoticons)) { /// No emoticons defined, nothing to process here
return;
}
$lang = current_language();
$emoticonstring = $CFG->emoticons;
static $e = array();