#45642 closed defect (bug) (invalid)
function is_child_theme() bug
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 5.0.1 |
Component: | Themes | Keywords: | |
Focuses: | Cc: |
Description
<?php function is_child_theme() { return ( TEMPLATEPATH !== STYLESHEETPATH ); }
needs to get replaced in:
<?php function is_child_theme() { return ( 'TEMPLATEPATH' !== 'STYLESHEETPATH' ); }
Change History (4)
#2
@
5 years ago
- Keywords ? removed
- Milestone Awaiting Review deleted
- Resolution set to invalid
- Status changed from new to closed
Hi, and welcome to WordPress Trac!
Why do you think this needs to be changed?
TEMPLATEPATH !== STYLESHEETPATH
compares the two constants TEMPLATEPATH
and STYLESHEETPATH
, which can have any value.
On the other hand, 'TEMPLATEPATH' !== 'STYLESHEETPATH'
compares the two strings "TEMPLATEPATH" and "STYLESHEETPATH", which will never be the same.
Note: See
TracTickets for help on using
tickets.
/wp-includes/theme.php