Make WordPress Core

Changeset 48795


Ignore:
Timestamp:
08/15/2020 01:44:00 PM (4 years ago)
Author:
SergeyBiryukov
Message:

Menus: Make the $object_id parameter of _wp_delete_post_menu_item() required, for consistency with _wp_delete_tax_menu_item().

The function is private (only intended for core usage) and is hooked to the delete_post action, which always passes a non-zero post ID.

Follow-up to [14295], [48794].

See #50343.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/nav-menu.php

    r48794 r48795  
    10391039 * @param int $object_id The ID of the original object being trashed.
    10401040 */
    1041 function _wp_delete_post_menu_item( $object_id = 0 ) {
     1041function _wp_delete_post_menu_item( $object_id ) {
    10421042    $object_id = (int) $object_id;
    10431043
Note: See TracChangeset for help on using the changeset viewer.