From ad652aa7bd511803316669a017da5246130d8f0b Mon Sep 17 00:00:00 2001 From: Laurel Date: Wed, 13 Mar 2024 08:59:55 -0700 Subject: [PATCH] fix: make sure sponsored categories, tags show sponsor info (#289) --- includes/theme-helpers.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/theme-helpers.php b/includes/theme-helpers.php index 522379d..388fc23 100644 --- a/includes/theme-helpers.php +++ b/includes/theme-helpers.php @@ -223,13 +223,13 @@ function get_sponsors_for_archive( $term_id = null, $scope = null, $logo_options if ( ! is_archive() ) { return new WP_Error( 'newspack-sponsors__is_not_archive', - __( 'Please provide a $term_id if not invoking within a term archive page.' ) + __( 'Please provide a $term_id if not invoking within a term archive page.', 'newspack-sponsors' ) ); } $term = get_queried_object(); } else { - $term = get_term_by( 'id', $term_id ); + $term = get_term_by( 'term_taxonomy_id', $term_id ); } // Return false if there's no term for this $term_id.