Jake Vanderwerf
2026-08-25 3d25ad7de4fdbb3eba2cde2a62422e6be5d79a0a
inc/registrar/config/Integration.php
@@ -1,6 +1,7 @@
<?php
namespace JVBase\registrar\config;
use JVBase\integrations\ServiceMap;
use JVBase\registrar\Registrar;
use JVBase\base\Site;
@@ -9,11 +10,13 @@
}
final class Integration extends Config{
   use ServiceMap;
   /**
    * @var string Must match as defined in the JVBase\integrations namespace
    */
   protected string $service_name;
   protected ?string $content_type = null;
   /**
    * @var bool Whether to send to the integration on publish
    */
@@ -54,7 +57,7 @@
      if (is_null($content)) {
         return $this;
      }
      $connection = JVB()->connect($this->service_name);
      $connection = $this->getService($this->service_name);
      if (!$connection){
         error_log('[Integration]::setContentType Service is not setup. '.$this->service_name);
         return $this;
@@ -62,7 +65,8 @@
      $allowed = $connection->getAllowedContent();
      if (!in_array($content, $allowed)) {
         error_log($this->service_name.' Connection does not support this content: '.$content);
         //TODO
//       error_log($this->service_name.' Connection does not support this content: '.$content);
         return $this;
      }
      $this->content_type = $content;
@@ -105,7 +109,6 @@
   public function setCustomer(bool $set):self
   {
      $this->isCustomer = $set;
//    JVB()->connect($this->service_name)->addCustomerFields();
      return $this;
   }