diff -r 7b1b88e27a20 -r 48c4eec2b7e6 wp/wp-includes/sitemaps/class-wp-sitemaps.php --- a/wp/wp-includes/sitemaps/class-wp-sitemaps.php Thu Sep 29 08:06:27 2022 +0200 +++ b/wp/wp-includes/sitemaps/class-wp-sitemaps.php Fri Sep 05 18:40:08 2025 +0200 @@ -14,6 +14,7 @@ * * @since 5.5.0 */ +#[AllowDynamicProperties] class WP_Sitemaps { /** * The main index of supported sitemaps. @@ -98,8 +99,8 @@ * * @since 5.5.0 * - * @param bool $is_enabled Whether XML Sitemaps are enabled or not. Defaults - * to true for public sites. + * @param bool $is_enabled Whether XML Sitemaps are enabled or not. + * Defaults to true for public sites. */ return (bool) apply_filters( 'wp_sitemaps_enabled', $is_enabled ); } @@ -249,12 +250,12 @@ * * @since 5.5.0 * - * @param string $output robots.txt output. - * @param bool $public Whether the site is public. + * @param string $output robots.txt output. + * @param bool $is_public Whether the site is public. * @return string The robots.txt output. */ - public function add_robots( $output, $public ) { - if ( $public ) { + public function add_robots( $output, $is_public ) { + if ( $is_public ) { $output .= "\nSitemap: " . esc_url( $this->index->get_index_url() ) . "\n"; }