import re


def matches(target, search_query):
    """
    Uses a regex to match the header title with the desired title
    :param target: The title to compare against
    :param search_query: The field to compare with
    :return: Boolean
    """
    title_regex = re.compile(search_query, re.IGNORECASE)
    res = title_regex.search(str(target))
    return res is not None