private function addSubscriberToAutomation($email, $subscriber, $websiteId)
    {
        $storeId = $subscriber->getStoreId();
        $store = $this->storeManager->getStore($storeId);
        $programId = $this->helper->getWebsiteConfig(
            'connector_automation/visitor_automation/subscriber_automation',
            $websiteId
        );

        //not mapped or subscriber is not new then ignore
        if (! $programId || ! $this->isSubscriberNew) {
            return;
        }

        //save subscriber to the queue
        $automation = $this->automationFactory->create()
            ->setEmail($email)
            ->setAutomationType(
                \Dotdigitalgroup\Email\Model\Sync\Automation::AUTOMATION_TYPE_NEW_SUBSCRIBER
            )
            ->setEnrolmentStatus(
                \Dotdigitalgroup\Email\Model\Sync\Automation::AUTOMATION_STATUS_PENDING
            )
            ->setTypeId($subscriber->getId())
            ->setWebsiteId($websiteId)
            ->setStoreName($store->getName())
            ->setProgramId($programId);
        $this->automationResource->save($automation);
    }