Opened 15 years ago
Closed 14 years ago
#10204 closed enhancement (worksforme)
Switch to using isset and typed comparison rather than empty
Reported by: | Denis-de-Bernardy | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 2.8 |
Component: | General | Keywords: | |
Focuses: | Cc: |
Description
There are multitudes of areas in WP where we're using empty to test for a variable, and where we'd be better of testing for isset($var) && $var !== false instead.
It is a tad bit faster, and it prevents bugs along the lines of #10203
Change History (1)
Note: See
TracTickets for help on using
tickets.
Please file bug reports for actual issues rather than broad things which we might be doing wrong somewhere.