From ba1e1ccf869b818f7a7a897264dfea05563a7796 Mon Sep 17 00:00:00 2001
From: Jake Vanderwerf <get@jakevanderwerf.ca>
Date: Sun, 07 Jun 2026 20:10:20 +0000
Subject: [PATCH] =Major overhaul of Integrations. Playing around with adding fields to post types through Registrar from an integrations' class file.

---
 inc/rest/routes/ShopRoutes.php |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/inc/rest/routes/ShopRoutes.php b/inc/rest/routes/ShopRoutes.php
index 4f69614..780b253 100644
--- a/inc/rest/routes/ShopRoutes.php
+++ b/inc/rest/routes/ShopRoutes.php
@@ -4,6 +4,7 @@
 use JVBase\JVB;
 use JVBase\managers\ImageGenerator;
 use JVBase\managers\UploadManager;
+use JVBase\registrar\Registrar;
 use JVBase\rest\RestRouteManager;
 use JVBase\meta\Meta;
 use WP_REST_Request;
@@ -150,7 +151,7 @@
         }
 
         $meta = Meta::forTerm($shop);
-		$allowed = jvbGetFields('shop', 'term');
+		$allowed = Registrar::getFieldsFor('shop');
 		$setData = array_filter(
 			$data,
 			function ($key) use ($allowed) {
@@ -173,7 +174,7 @@
             }
 		}
 
-		$results = $meta->setAll($setData);
+		$meta->setAll($setData);
 
 //        $results = [];
 //
@@ -1393,7 +1394,6 @@
         }
         $owners = implode(',', $owners);
         $shopMeta->set($sMeta, $owners);
-
         return true;
     }
 }

--
Gitblit v1.10.0