diff --git a/bson/objectid.py b/bson/objectid.py index 357554fcd..4abf7ca57 100644 --- a/bson/objectid.py +++ b/bson/objectid.py @@ -235,6 +235,11 @@ class ObjectId(object): return self.__id == other.__id return NotImplemented + def __ne__(self,other): + if isinstance(other, ObjectId): + return self.__id != other.__id + return NotImplemented + def __lt__(self, other): if isinstance(other, ObjectId): return self.__id < other.__id