From c156c7700225e77120dec04c4594ef753f9c86b4 Mon Sep 17 00:00:00 2001 From: Max Kostikov Date: Wed, 6 Dec 2017 19:49:53 +0200 Subject: [PATCH] update for PHP 7.2 compatibility --- bl-kernel/helpers/text.class.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/bl-kernel/helpers/text.class.php b/bl-kernel/helpers/text.class.php index d6a92895..012ba61c 100644 --- a/bl-kernel/helpers/text.class.php +++ b/bl-kernel/helpers/text.class.php @@ -234,7 +234,9 @@ class Text { public static function pre2htmlentities($string) { return preg_replace_callback('/(.*?)<\/code><\/pre>/imsu', - create_function('$input', 'return "
".htmlentities($input[2])."
";'), + function ($input) { + return "
".htmlentities($input[2])."
"; + }, $string); } @@ -263,4 +265,4 @@ class Text { return $truncate; } -} \ No newline at end of file +}