Make WordPress Core

Changeset 57946


Ignore:
Timestamp:
04/08/2024 09:40:02 PM (8 months ago)
Author:
jorgefilipecosta
Message:

Coding Standards: Fix missing strict in_array on block-template-utils.php.

Props swissspidy.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/block-template-utils.php

    r57944 r57946  
    14811481    }
    14821482    $valid_template_types = array( '404', 'archive', 'attachment', 'author', 'category', 'date', 'embed', 'frontpage', 'home', 'index', 'page', 'paged', 'privacypolicy', 'search', 'single', 'singular', 'tag', 'taxonomy' );
    1483     if ( in_array( $template_type, $valid_template_types ) ) {
     1483    if ( in_array( $template_type, $valid_template_types, true ) ) {
    14841484        /** This filter is documented in wp-includes/template.php */
    14851485        return apply_filters( "{$template_type}_template_hierarchy", $template_hierarchy );
Note: See TracChangeset for help on using the changeset viewer.