def direction_string_cleaner(record):
    """
    Pandas Helper Function to clean a record in the "direction" column.

    Args:
        record (str): Strings in "direction" column.

    Returns:
        str: Cleaned string.
    """
    if "eastbound" in str(record):
        return "eastbound"
    elif "northbound" in str(record):
        return "northbound"
    elif "southbound" in str(record):
        return "southbound"
    elif "westbound" in str(record):
        return "westbound"
    elif "clockwise" in str(record):
        return "clockwise"
    elif "anti-clockwise" in str(record):
        return "clockwise"
    elif "legacy site" in str(record):
        return "legacy site"
    elif "on connector" in str(record):
        return "carriageway connector"
    else:
        return record