def escape_markdown(content):
    """
    Escapes markdown from the given content.
    
    Parameters
    ----------
    content : `None` or `str`
        The content to sanitize.
    
    Returns
    -------
    content : `None` or `str`
    """
    if (content is None):
        return
    
    content = content.replace('\\', '\\\\')
    content = content.replace('_', '\\_')
    content = content.replace('*', '\\*')
    content = content.replace('|', '\\|')
    content = content.replace('~', '\\~')
    content = content.replace('`', '\\`')
    content = content.replace('>', '\\>')
    content = content.replace(':', '\\:')
    return content