private function searchUrl(NewsItemEntity $newsItem)
    {
        $pattern = '/[-a-zA-Z0-9:%_\+.~#?&\/\/=]{2,256}\.[a-z]{2,10}\b(\/[-a-zA-Z0-9:%_\+.~#?&\/\/=]*)?/i';

        if (!preg_match($pattern, $newsItem->getMessage(), $matches)) {
            // No link found, so set link data to null.
            return $this->unsetUrl($newsItem);
        }

        $url = $matches[0];

        $result = $this->scrapeUrl($url);

        if (empty($result)) {
            return $this->unsetUrl($newsItem);
        }

        $newsItem->setLinkUrl(ParserUtil::sanitizeUrl($url));
        $newsItem->setLinkTitle($result['title']);
        $newsItem->setLinkDescription($result['description']);

        return $newsItem;
    }