[FIX] base_action_rule: Encoding error while Regex has non string character
author <JoƫlGrand-Guillaume@CampToCamp> <>
Thu, 2 Feb 2012 12:40:58 +0000 (18:10 +0530)
committerRifakat (OpenERP) <rha@tinyerp.com>
Thu, 2 Feb 2012 12:40:58 +0000 (18:10 +0530)
lp bug: https://launchpad.net/bugs/921442 fixed

bzr revid: rha@tinyerp.com-20120202124058-626muirhldyrtxak

addons/base_action_rule/base_action_rule.py

index fda47f1..5fa8528 100644 (file)
@@ -356,8 +356,8 @@ the rule to mark CC(mail to any other person defined in actions)."),
         reg_name = action.regex_name
         result_name = True
         if reg_name:
-            ptrn = re.compile(str(reg_name))
-            _result = ptrn.search(str(obj.name))
+            ptrn = re.compile(reg_name)
+            _result = ptrn.search(obj.name)
             if not _result:
                 result_name = False
         regex_n = not reg_name or result_name