static function getTextLengthWithShortUrls($text, $shortUrlLength = 23)
    {
        if($shortUrlLength < 7){
            throw new \Exception('URL must be at least 7 characters long.');
        }

        // Create dummy short URL.
        $shortUrl = substr(str_shuffle("0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"), 0, $shortUrlLength - 7);
        $shortUrl = 'http://'.$shortUrl;

        return mb_strlen(preg_replace(self::REGEX_URL, $shortUrl, $text), 'UTF-8');
    }