Make WordPress Core

Opened 13 years ago

Closed 13 years ago

#18583 closed defect (bug) (invalid)

is_post_type_archive() shouldn't return true if is_search() is true

Reported by: ocean90's profile ocean90 Owned by:
Milestone: Priority: normal
Severity: normal Version: 3.1
Component: Query Keywords:
Focuses: Cc:

Description

  • Register a post type.
  • Do a search domain.com/post_type/?s=foo
  • Result: is_post_type_archive() will return true, is_archive() too.

In my opinion is_post_type_archive() shouldn't return true on a search.

Attachments (1)

18583.patch (599 bytes) - added by ocean90 13 years ago.

Download all attachments as: .zip

Change History (4)

@ocean90
13 years ago

#1 @scribu
13 years ago

  • Keywords needs-unit-tests added

#2 @scribu
13 years ago

Also, what's the rationale?

What's the situation with ?author_name=foo&s=bar etc.?

#3 @ocean90
13 years ago

  • Keywords has-patch needs-unit-tests removed
  • Milestone Awaiting Review deleted
  • Resolution set to invalid
  • Status changed from new to closed

Error in reasoning.

Note: See TracTickets for help on using tickets.