services:
    _defaults:
        public: true

    prestashop.adapter.module.prestatrust.checker:
        class: PrestaShop\PrestaShop\Adapter\Module\PrestaTrust\PrestaTrustChecker
        arguments:
            - "@doctrine.cache.provider"
            - "@prestashop.addons.client_api"
            - "@translator"

    prestashop.adapter.module.prestatrust.eventsubscriber:
        class: PrestaShop\PrestaShop\Adapter\Module\PrestaTrust\ModuleEventSubscriber
        arguments:
            - "@prestashop.adapter.module.prestatrust.checker"
        calls:
            - [ setEnabled, ['%prestashop.addons.prestatrust.enabled%']]
        tags:
            - { name: kernel.event_subscriber }
