def validate_list_or_none(option, value):
    """Validates that 'value' is a list or None."""
    if value is None:
        return value
    return validate_list(option, value)
Validates that 'value' is a list or None.
stackoverflow/venv/lib/python3.6/site-packages/pymongo/common.py