Browse Source

[desktop] Don't compare regexes by address

Erick Tryzelaar 10 năm trước cách đây
mục cha
commit
4a6448f970
1 tập tin đã thay đổi với 2 bổ sung1 xóa
  1. 2 1
      desktop/core/src/desktop/redaction/engine.py

+ 2 - 1
desktop/core/src/desktop/redaction/engine.py

@@ -119,7 +119,8 @@ class RedactionRule(object):
     return \
         isinstance(other, self.__class__) and \
         self.trigger == other.trigger and \
-        self.regex == other.regex and \
+        self.regex.pattern == other.regex.pattern and \
+        self.regex.flags == other.regex.flags and \
         self.replace == other.replace
 
   def __ne__(self, other):