Opened 10 years ago
Last modified 6 years ago
#31935 new defect (bug)
is_page() erroneously set to true when loading /feed/ associated with 404
Reported by: | danielbachhuber | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 4.0 |
Component: | Feeds | Keywords: | has-patch has-unit-tests |
Focuses: | Cc: |
Description
r29216 changed feeds to never send a 404 status header. This had the unintended consequence of changing the behavior of some internals.
A request to the feed associated with a missing page (e.g. /missing-page/feed/
) will match the rewrite rule for a page and set is_page == true
. I'd expect WordPress internals to still understand this request as is_404
Attachments (2)
Change History (8)
#1
@
10 years ago
- Keywords has-patch added; needs-patch removed
This can be fixed by sending 200 status code only for home page feed. Therefore, I added !is_singular()
along with is_feed()
Any other better way ?
#3
@
9 years ago
- Keywords has-unit-tests added; needs-unit-tests removed
- Milestone changed from Future Release to 4.5
Note: See
TracTickets for help on using
tickets.
Patch checking not singular with is_feed