WordPress.org

Make WordPress Core

Ticket #24674: ispage.patch

File ispage.patch, 706 bytes (added by clifgriffin, 10 months ago)
  • wp-includes/query.php

    From cee2b6d039ba1810c26cd172ee532d5b817ab725 Mon Sep 17 00:00:00 2001
    From: Clifton Griffin <clifgriffin@gmail.com>
    Date: Tue, 2 Jul 2013 11:04:47 -0400
    Subject: [PATCH] Minor patch to is_page()
    
    ---
     wp-includes/query.php |    2 +-
     1 file changed, 1 insertion(+), 1 deletion(-)
    
    diff --git a/wp-includes/query.php b/wp-includes/query.php
    index 443d0bb..9708d24 100644
    a b class WP_Query { 
    33823382 
    33833383                $page = (array) $page; 
    33843384 
    3385                 if ( in_array( $page_obj->ID, $page ) ) 
     3385                if ( in_array( $page_obj->ID, $page, true ) ) 
    33863386                        return true; 
    33873387                elseif ( in_array( $page_obj->post_title, $page ) ) 
    33883388                        return true;