protected function _addLinksToCashtags($matches)
{
list($all, $before, $cash, $tag, $after) = array_pad($matches, 5, '');
if (preg_match(self::$patterns['end_cashtag_match'], $after) || !preg_match('!\\A["\']!', $before) && preg_match('!\\A["\']!', $after) || preg_match('!\\A</!', $after)) {
return $all;
}
$replacement = $before;
$element = $cash . $tag;
$url = $this->url_base_cash . $tag;
$replacement .= $this->wrapHash($url, $this->class_cash, $element);
return $replacement;
}