From ca0c76e663c3e5c1b20db09057fb137fa025a58f Mon Sep 17 00:00:00 2001 From: Nicolas Lemoine Date: Sat, 23 Sep 2023 15:58:22 +0200 Subject: [PATCH] Fix get author term field The field used to map user ID is the slug (used elsewhere to make relevant tax queries) --- inc/template.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/template.php b/inc/template.php index 761288a..f1335c2 100644 --- a/inc/template.php +++ b/inc/template.php @@ -35,7 +35,7 @@ function get_author_ids( WP_Post $post ) : array { } return array_map( function ( WP_Term $term ) : int { - return intval( $term->name ); + return intval( $term->slug ); }, $authors ); }