Opened 8 years ago
Last modified 6 years ago
#37253 new defect (bug)
Add several missing "_deprecated_function()" calls
Reported by: | ramiy | Owned by: | |
---|---|---|---|
Milestone: | Future Release | Priority: | low |
Severity: | normal | Version: | |
Component: | General | Keywords: | has-patch needs-refresh |
Focuses: | Cc: |
Description
I found 13 deprecated functions that don't use _deprecated_function()
.
We have to use the deprecated functions call to trigger an error when WP_DEBUG
is true
. It helps developers to catch and fix their code.
See the attached patch.
Attachments (1)
Change History (7)
#3
@
8 years ago
By the way, each and every WordPress deprecated function uses _deprecated_function()
. All, besides those 13 functions in the patch.
#5
follow-up:
↓ 6
@
8 years ago
- Keywords needs-refresh added
- Milestone changed from 4.6 to Future Release
- Priority changed from normal to low
I don't think we need to add them to functions which were previously used as callbacks. For the screen icon see [26537]. WP_Screen::render_screen_meta()
is not a direct replacement for screen_meta()
, it should be something like screen_options()
or screen_layout()
is using.
#6
in reply to:
↑ 5
@
8 years ago
Replying to ocean90:
I don't think we need to add them to functions which were previously used as callbacks. For the screen icon see [26537].
WP_Screen::render_screen_meta()
is not a direct replacement forscreen_meta()
, it should be something likescreen_options()
orscreen_layout()
is using.
@ocean90, what about the other functions? The patch adds _deprecated_function()
to 13 functions.
It's important because I still see many plugins that use
get_screen_icon()
andscreen_icon()
.Many developers don't know that they use those deprecated function because those functions don't call
_deprecated_function()
.