From ad99fdaae41e0a2d65e7123e9bd222351a8648f8 Mon Sep 17 00:00:00 2001 From: Matthias Pfefferle Date: Thu, 12 Sep 2024 16:55:14 +0200 Subject: [PATCH] use is_blog_public --- includes/model/class-blog.php | 3 ++- includes/model/class-user.php | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/includes/model/class-blog.php b/includes/model/class-blog.php index 9718703c7..7db80fd93 100644 --- a/includes/model/class-blog.php +++ b/includes/model/class-blog.php @@ -11,6 +11,7 @@ use function Activitypub\esc_hashtag; use function Activitypub\is_single_user; +use function Activitypub\is_blog_public; use function Activitypub\is_user_disabled; use function Activitypub\get_rest_url_by_path; @@ -381,7 +382,7 @@ public function get_featured() { } public function get_indexable() { - if ( \get_option( 'blog_public', 1 ) ) { + if ( is_blog_public() ) { return true; } else { return false; diff --git a/includes/model/class-user.php b/includes/model/class-user.php index f76abecee..d0b7faf0e 100644 --- a/includes/model/class-user.php +++ b/includes/model/class-user.php @@ -10,6 +10,7 @@ use Activitypub\Collection\Users; use Activitypub\Collection\Extra_Fields; +use function Activitypub\is_blog_public; use function Activitypub\is_user_disabled; use function Activitypub\get_rest_url_by_path; @@ -271,7 +272,7 @@ public function get_tag() { } public function get_indexable() { - if ( \get_option( 'blog_public', 1 ) ) { + if ( is_blog_public() ) { return true; } else { return false;