From daefb9bdacbcf1b4c6e3d701a4706a0addc383f2 Mon Sep 17 00:00:00 2001 From: HerrVigg Date: Thu, 17 Feb 2022 23:23:52 +0100 Subject: [PATCH] QTS: delete unused function raising warning in PHP8.1 (#1103) --- modules/slugs/includes/termmeta-core.php | 25 +----------------------- 1 file changed, 1 insertion(+), 24 deletions(-) diff --git a/modules/slugs/includes/termmeta-core.php b/modules/slugs/includes/termmeta-core.php index aa3cbb43..2ae3952b 100644 --- a/modules/slugs/includes/termmeta-core.php +++ b/modules/slugs/includes/termmeta-core.php @@ -170,7 +170,7 @@ function delete_term_meta_by_key( $term_meta_key ) { * * @return array */ -if ( ! function_exists( 'add_term_meta' ) ): +if ( ! function_exists( 'get_term_custom' ) ): function get_term_custom( $term_id ) { $term_id = (int) $term_id; @@ -204,26 +204,3 @@ function get_term_custom_keys( $term_id ) { } } endif; - -/** - * Retrieve values for a custom term field. - * - * The parameters must not be considered optional. All of the term meta fields - * will be retrieved and only the meta field key values returned. - * - * @param string $key Meta field key. - * @param int $term_id Term ID - * - * @return array Meta field values. - */ -if ( ! function_exists( 'get_term_custom_values' ) ): - function get_term_custom_values( $key = '', $term_id ) { - if ( ! $key ) { - return null; - } - - $custom = get_term_custom( $term_id ); - - return isset( $custom[ $key ] ) ? $custom[ $key ] : null; - } -endif;