Make WordPress Core

Opened 11 years ago

Last modified 5 years ago

#24284 new enhancement

is_multi_author() should query by specific post type and status

Reported by: alex-ye's profile alex-ye Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: General Keywords: has-patch needs-refresh needs-unit-tests
Focuses: Cc:

Description

Current is_multi_author() function only checks by the 'post' post-type and 'publish' post-status..

I think the function should be able to query by custom-post-type and custom-post-status

Attachments (1)

author-templates.patch (2.6 KB) - added by alex-ye 11 years ago.
First Try :)

Download all attachments as: .zip

Change History (4)

@alex-ye
11 years ago

First Try :)

#1 @SergeyBiryukov
11 years ago

Note that the function is filterable (#18600), so a workaround is currently possible.

#2 @cais
10 years ago

Good thing I searched first, although this is not what I had in mind ...

... looking through my notes for some feature ideas I happened across the is_multi_author function and thought I might put it to use, at least until I saw it was basically incomplete for a standard WordPress installation. It would be negligent to think WordPress installations could only be filled with posts for multiple authors. I would actually more expect to see multiple authors when the installation is only filled with pages and looking at this function as is, it only queries for posts and ignores the possibility another author may only write pages, or that the site only contains pages and no posts.

Modifying the query should be easy enough to also take into account pages

#3 @chriscct7
8 years ago

  • Keywords has-patch needs-refresh needs-unit-tests added; needs-patch removed
Note: See TracTickets for help on using tickets.