[source host alias] match_host is the attribute, match is the method
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Mon, 07 Mar 2011 23:16:22 +0100
changeset 7049 f2ae6202754c
parent 7048 453c7bbae3ff
child 7059 1d65b235549f
[source host alias] match_host is the attribute, match is the method
hooks/syncsources.py
--- a/hooks/syncsources.py	Mon Mar 07 22:17:23 2011 +0100
+++ b/hooks/syncsources.py	Mon Mar 07 23:16:22 2011 +0100
@@ -89,7 +89,7 @@
     __select__ = SourceHook.__select__ & is_instance('CWSourceHostConfig')
     events = ('after_add_entity', 'after_update_entity', 'before_delete_entity',)
     def __call__(self):
-        if self.entity.match_host(gethostname()):
+        if self.entity.match(gethostname()):
             if self.event == 'after_update_entity' and \
                    not 'config' in self.entity.cw_edited:
                 return