(stix_objects)
return list(
        filter(
            lambda x: x.get("x_mitre_deprecated", False) is False and x.get("revoked", False) is False,
            stix_objects
        )
    )
Will remove any revoked or deprecated objects from queries made to the data source
Will remove any revoked or deprecated objects from queries made to the data source
Will remove any revoked or deprecated objects from queries made to the data source
def remove_deprecated(stix_objects):
    """Will remove any revoked or deprecated objects from queries made to the data source"""
    # Note we use .get() because the property may not be present in the JSON data. The default is False
    # if the property is not set.
    return list(
        filter(
            lambda x: x.get("x_mitre_deprecated", False) is False and x.get("revoked", False) is False,
            stix_objects
        )
    )
def remove_deprecated ( stix_objects ) : # Note we use .get() because the property may not be present in the JSON data. The default is False # if the property is not set. return list ( filter ( lambda x : x . get ( "x_mitre_deprecated" , False ) is False and x . get ( "revoked" , False ) is False , stix_objects ) )