Remove anonymous function, 5.2 is still minimal requirement

This commit is contained in:
Fabrixxm 2015-11-13 09:36:22 +01:00
parent dab544ab76
commit fa4ee05312

View file

@ -90,9 +90,11 @@ function html2bbcode($message)
$message = str_replace("\r", "", $message);
$message = preg_replace_callback("|<pre><code>([^<]*)</code></pre>|ism", function($m) {
function _replace_code_cb($m){
return "<code>".str_replace("\n","<br>\n",$m[1]). "</code>";
}, $message);
}
$message = preg_replace_callback("|<pre><code>([^<]*)</code></pre>|ism", "_replace_code_cb", $message);
$message = str_replace(array(
"<li><p>",