From 1d5c574e6efc88a32a76f645c27f459aad0e65df Mon Sep 17 00:00:00 2001
From: Jake Vanderwerf <get@jakevanderwerf.ca>
Date: Thu, 01 Jan 2026 21:12:08 +0000
Subject: [PATCH] =Minor fix to extractTaxonomies
---
inc/rest/routes/FeedRoutes.php | 13 ++++++++-----
1 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/inc/rest/routes/FeedRoutes.php b/inc/rest/routes/FeedRoutes.php
index 098441e..3b9799e 100644
--- a/inc/rest/routes/FeedRoutes.php
+++ b/inc/rest/routes/FeedRoutes.php
@@ -40,7 +40,7 @@
$this->cache->clear();
$this->checker = Checker::getInstance();
- if (jvbSiteUsesUmami()) {
+ if (Features::hasIntegration('umami')) {
$this->tracker = JVB()->connect('umami');
}
$this->setupCacheConnections();
@@ -277,14 +277,17 @@
return $cache->remember(
'feed_link_'.$term->term_id,
function () use ($term, $postID, $type) {
- return [
+ $base = [
'ID' => $term->term_id,
'title' => htmlspecialchars_decode($term->name),
'url' => get_term_link($term->term_id, $term->taxonomy),
- 'umami_click' => $this->tracker->trackTaxonomyClick($term->term_id, $term->taxonomy, [
- 'from' => $type . '_' . $postID
- ])
];
+ if ($this->tracker) {
+ $base['umami_click'] =$this->tracker->trackTaxonomyClick($term->term_id, $term->taxonomy, [
+ 'from' => $type . '_' . $postID
+ ]);
+ }
+ return $base;
}
);
}
--
Gitblit v1.10.0