def METHOD_NAME(path=None):
    if path is None:
        path = _get_path_lowercase()
    try:
        pos = path.index(name.lower())
    except ValueError:
        return None
    else:
        if index is not None and index < 0:
            # Since a negative index was used, convert the index to a
            # negative index to make the changes dict easier to read, as
            # well as making comparisons manageable.
            return -(len(path) - pos)
        else:
            return pos