[wp-trac] [WordPress Trac] #15773: Replace $is_singular with is_singular() (was: Drop $is_singular)
WordPress Trac
wp-trac at lists.automattic.com
Mon Dec 13 20:20:06 UTC 2010
#15773: Replace $is_singular with is_singular()
-------------------------+--------------------------------------------------
Reporter: scribu | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Query | Version:
Severity: normal | Keywords: php5 has-patch
-------------------------+--------------------------------------------------
Old description:
> The $is_singular flag is just an alias for $is_post || $is_page ||
> $is_attachment.
>
> Being a variable means we have to also keep it current whenever one of
> it's components changes.
>
> But since we have an is_singular() method now, we could deprecate it.
New description:
The $is_singular flag is just an alias for {{{$is_post || $is_page ||
$is_attachment.}}}
Being a variable means we have to also keep it current whenever one of
it's components changes.
I propose we use the is_singular() method, and deprecate $is_singular.
--
Comment(by scribu):
You are missing something, yeah, but it's my fault. Updated ticket for
clarity.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/15773#comment:3>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list