[wp-trac] [WordPress Trac] #44383: Deprecate the media_buttons_context filter with apply_filters_deprecated()
WordPress Trac
noreply at wordpress.org
Mon Jun 18 16:02:11 UTC 2018
#44383: Deprecate the media_buttons_context filter with apply_filters_deprecated()
----------------------------------------+------------------------------
Reporter: birgire | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Media | Version: 3.5
Severity: normal | Resolution:
Keywords: needs-patch good-first-bug | Focuses:
----------------------------------------+------------------------------
Comment (by audrasjb):
Hi @zsiderov , welcome to WordPress Trac and thanks for your patch :)
I guess you should use `__()` function to localize this string.
Also, `array()` should do the job.
{{{#!php
$legacy_filter = apply_filters_deprecated( 'media_buttons_context',
array(), '3.5.0', false, __( 'Please use "media_buttons" action instead.'
) );
}}}
Cheers,
Jb
--
Ticket URL: <https://core.trac.wordpress.org/ticket/44383#comment:4>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list