diff -r ac54083bbe98 -r 8927221a0675 src/pyams_mail/mailer.py --- a/src/pyams_mail/mailer.py Thu Jun 02 15:46:08 2016 +0200 +++ b/src/pyams_mail/mailer.py Tue Nov 15 09:59:17 2016 +0100 @@ -16,19 +16,15 @@ # import interfaces from pyramid_mailer.interfaces import IMailer -from zope.schema.interfaces import IVocabularyFactory # import packages -from zope.interface import provider +from pyams_utils.vocabulary import vocabulary_config from zope.componentvocabulary.vocabulary import UtilityVocabulary -from zope.schema.vocabulary import getVocabularyRegistry -@provider(IVocabularyFactory) +@vocabulary_config(name='PyAMS mailer utilities') class MailerVocabulary(UtilityVocabulary): """Mailer vocabulary""" interface = IMailer nameOnly = True - -getVocabularyRegistry().register('PyAMS mailer utilities', MailerVocabulary)