Commit 0169d11e authored by Vincent Pelletier's avatar Vincent Pelletier

Unset self.isColumn value before returning: it is a method bound to a...

Unset self.isColumn value before returning: it is a method bound to a persistent object, so it might do bad things.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@26796 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent b23585e9
...@@ -91,6 +91,7 @@ class AdvancedSearchTextDetector(lexer): ...@@ -91,6 +91,7 @@ class AdvancedSearchTextDetector(lexer):
def __call__(self, input, is_column): def __call__(self, input, is_column):
self.isColumn = is_column self.isColumn = is_column
try:
self.found = False self.found = False
check_grammar = False check_grammar = False
self.token_list = token_list = [] self.token_list = token_list = []
...@@ -106,6 +107,8 @@ class AdvancedSearchTextDetector(lexer): ...@@ -106,6 +107,8 @@ class AdvancedSearchTextDetector(lexer):
if not self.found and check_grammar: if not self.found and check_grammar:
self.found = self.parse() self.found = self.parse()
return self.found return self.found
finally:
self.isColumn = None
update_docstrings(AdvancedSearchTextDetector) update_docstrings(AdvancedSearchTextDetector)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment