From 235ce5716edc2f7cbe80fdccf26eac7269587839 Mon Sep 17 00:00:00 2001
From: Jake Vanderwerf <get@jakevanderwerf.ca>
Date: Mon, 08 Jun 2026 04:38:18 +0000
Subject: [PATCH] =FavouritesManager.php and FavouritesRoutes.php fixes. Moving all logic to FavouritesManager.php. Still some left to do

---
 inc/registrar/helpers/HideSingle.php |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/inc/registrar/helpers/HideSingle.php b/inc/registrar/helpers/HideSingle.php
index 20ef320..9c00ca8 100644
--- a/inc/registrar/helpers/HideSingle.php
+++ b/inc/registrar/helpers/HideSingle.php
@@ -12,15 +12,14 @@
 class HideSingle {
 	protected string $slug;
 	protected string $postType;
-	protected Registrar $registrar;
 	public function __construct(string $slug, Registrar $registrar) {
 		$this->slug = $slug;
 		$this->postType = jvbCheckBase($slug);
-		$this->registrar = $registrar;
 
-		if ($this->registrar->hasFeature('hide_single')) {
+
+		if ($registrar->hasFeature('hide_single')) {
 			add_filter('is_post_type_viewable', [$this, 'hideFromPublic']);
-			if ($this->registrar->hasFeature('redirect_to_author')) {
+			if ($registrar->hasFeature('redirect_to_author')) {
 				add_filter('post_type_link', [$this, 'redirectSingleToAuthor'], 15, 2);
 				add_action('template_redirect', [$this, 'actuallyRedirectToAuthor']);
 			} else {

--
Gitblit v1.10.0