I've upgraded Media module from 2.0-alpha2+6-dev and 2.0-beta1, however now I've the following error on some random pages:
( ! ) Fatal error: Call to undefined function `media_filter()` in my_module.module on line 224
My code in hook_field_formatter_view
in my module is:
$element[0]['#markup']
= '<div class="my-formatter-slide-down-container"><div class="text-summary ' . ($settings['hide_summary'] ? 'hiding' : '') . '">'
. media_filter($text_summary)
. '<a href="' . $read_more_link . '" class="read-more">' . $read_more_text . '</a>'
. '</div></div>';
The code of that media_filter
function was:
function media_filter($text) {
$text = preg_replace_callback(MEDIA_TOKEN_REGEX, 'media_token_to_markup', $text);
return $text;
}
What is the current replacement for that function which I can use instead?