# HG changeset patch # User Thierry Florac # Date 1520646095 -3600 # Node ID c56c448550006e60f5ad02a58a87f8e0f47c0eb9 # Parent 95208835857e9926cab4175dd80558dfdf2b9196 Updated database upgrade code and removed INewLocalSite event subscriber diff -r 95208835857e -r c56c44855000 src/pyams_catalog/site.py --- a/src/pyams_catalog/site.py Sat Mar 10 02:40:12 2018 +0100 +++ b/src/pyams_catalog/site.py Sat Mar 10 02:41:35 2018 +0100 @@ -23,7 +23,6 @@ from pyams_utils.interfaces.site import ISiteGenerations from zope.intid.interfaces import IIntIds, IIntIdRemovedEvent from zope.lifecycleevent.interfaces import IObjectAddedEvent, IObjectModifiedEvent -from zope.site.interfaces import INewLocalSite # import packages from hypatia.catalog import Catalog @@ -39,17 +38,11 @@ (ICatalog, '', Catalog, 'Catalog'),) -@subscriber(INewLocalSite) -def handle_new_local_site(event): - """Create a new catalog when a site is created""" - site = event.manager.__parent__ - check_required_utilities(site, REQUIRED_UTILITIES) - - @utility_config(name='PyAMS catalog', provides=ISiteGenerations) class CatalogGenerationsChecker(object): """Catalog generations checker""" + order = 40 generation = 1 def evolve(self, site, current=None):