Opened 11 years ago
Closed 11 years ago
#27133 closed enhancement (fixed)
Redundant type casting in wp_get_object_terms
Reported by: | OriginalEXE | Owned by: | wonderboymusic |
---|---|---|---|
Milestone: | 3.9 | Priority: | normal |
Severity: | minor | Version: | 3.9 |
Component: | Taxonomy | Keywords: | has-patch |
Focuses: | Cc: |
Description
In wp_get_object_terms function (taxonomy.php), there is a redundant type casting to array after is_array() check has already been performed on that variable.
Attachments (1)
Change History (6)
#1
@
11 years ago
- Keywords has-patch added
- Severity changed from normal to minor
I have attached a patch removing the unnecessary type casting. It is, however, worth considering replacing all is_array() checks with direct type casting, which appears to be faster in php.
Note: See
TracTickets for help on using
tickets.
Proposed improvement