<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def meta_redirect(content):
 """ Returns redirecting URL if there is a HTML refresh meta tag, returns None otherwise :param content: HTML content """

    decoded = content.decode("utf-8", errors="replace")

    try:
        soup = BeautifulSoup.BeautifulSoup(decoded)
    except Exception as e:
        return None

    result = soup.find("meta", attrs={"http-equiv": re.compile("^refresh$", re.I)})
    if result:
        try:
            wait, text = result["content"].split(";")
            text = text.strip()
            if text.lower().startswith("url="):
                url = text[4:]
                return url
        except:
            # there are normal meta tag with refresh that are not
            # redirect and don't have a URL in it
            pass
    return None