From 1b65d22eaa512c2d81e4d7539e02ff9bca7fe983 Mon Sep 17 00:00:00 2001 From: Emmanuel Garette Date: Thu, 19 Dec 2019 15:00:46 +0100 Subject: [PATCH] valid_enum is a valid function --- src/rougail/annotator.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/rougail/annotator.py b/src/rougail/annotator.py index dc7c3c58e..2d924f636 100644 --- a/src/rougail/annotator.py +++ b/src/rougail/annotator.py @@ -981,8 +981,10 @@ class SpaceAnnotator(object): for idx in remove_indexes: del space[idx] remove_indexes = [] + functions = dir(self.eosfunc) + functions.append('valid_enum') for idx, check in enumerate(space): - if not check.name in dir(self.eosfunc): + if not check.name in functions: raise CreoleDictConsistencyError(_('cannot find check function {}').format(check.name)) #is_probe = not check.name in self.eosfunc.func_on_zephir_context #if is_probe: