[wp-trac] [WordPress Trac] #32544: No function exposes all supported MIME types

WordPress Trac noreply at wordpress.org
Tue Jun 9 05:59:18 UTC 2015


#32544: No function exposes all supported MIME types
----------------------------------------+------------------------------
 Reporter:  dan.rossiter                |       Owner:
     Type:  enhancement                 |      Status:  new
 Priority:  low                         |   Milestone:  Awaiting Review
Component:  Media                       |     Version:  4.2.2
 Severity:  normal                      |  Resolution:
 Keywords:  needs-patch good-first-bug  |     Focuses:
----------------------------------------+------------------------------

Comment (by dan.rossiter):

 Replying to [comment:5 ipm-frommen]:
 > I'm talking about the recursion (i.e., `get_service_mime_types` being
 called within `get_service_mime_types`).
 Gotcha. That would be a typo; pretend the internal call gets a full
 unfiltered list of all MIME types supported by the service -- maybe via an
 HTTP request or some cached option.
 >
 > Regarding your desired functionality, could you (again) explain in more
 detail what you want exactly? With the current `upload_mimes` filter (and
 its parameters), I don't see any way to achieve what (I guess) you want.
 If your ''structural change'' implicates removing the `$user` ID field
 from the filter's parameters, this, of course, breaks backwards
 compatibility.
 I was thinking the opposite, actually. Add an additional "override" param
 which tells the function to unconditionally include all MIME types
 regardless of user. Short of a complete rework of how MIME types are
 tracked, this seems like the cleanest solution to me.
 >
 > I'm afraid, I just didn't understand what you would like to have.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/32544#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list