def METHOD_NAME(name):
    if name is None:
        return ""
    if "/" in name:
        return name.split("/")[0].lower().strip()
    if " " in name:
        names = name.split(" ")[:-1]
        return " ".join(names).lower().strip()
    return name