[wp-trac] [WordPress Trac] #36901: Removing wp_die() from wp_allow_comment()
WordPress Trac
noreply at wordpress.org
Thu Sep 29 04:54:00 UTC 2016
#36901: Removing wp_die() from wp_allow_comment()
-------------------------------------------------+-------------------------
Reporter: websupporter | Owner:
Type: enhancement | rachelbaker
Priority: normal | Status: assigned
Component: Comments | Milestone: 4.7
Severity: normal | Version: 4.6
Keywords: has-patch needs-testing has-unit- | Resolution:
tests | Focuses:
-------------------------------------------------+-------------------------
Comment (by rachelbaker):
[attachment:36901.diff] is a riff off of [attachment:36901.2.patch].
Changes include:
- Changed the `$return_error` variable to `$avoid_die`, still defaulting
to `false`.
- Removed the `check_comment_flood_db()` function from the
`check_comment_flood` action. Still keeping the `do_action(
'check_comment' )` in `wp_allow_comment()` for back-compat.
- Call the `check_comment_flood_db()` function directly from within
`wp_allow_comment()` instead of adding a wrapper function or filter.
@boonebgorges any back-compat concerns here that I am missed?
- Added missing `@since` tags.
- Added missing `@return` types of `WP_Error` where possible.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/36901#comment:13>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list