Make WordPress Core

Changeset 55306


Ignore:
Timestamp:
02/11/2023 01:10:22 PM (14 months ago)
Author:
SergeyBiryukov
Message:

Coding Standards: Pass correct value to get_delete_post_link() in attachment_submit_meta_box().

The $deprecated parameter of get_delete_post_link() is documented to accept a string, not null.

Follow-up to [14099], [21948].

Props krunal265, jrf.
Fixes #57690.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/meta-boxes.php

    r55276 r55306  
    473473        } else {
    474474            $delete_ays = ! MEDIA_TRASH ? " onclick='return showNotice.warn();'" : '';
    475             echo "<a class='submitdelete deletion'$delete_ays href='" . get_delete_post_link( $post->ID, null, true ) . "'>" . __( 'Delete permanently' ) . '</a>';
     475            echo "<a class='submitdelete deletion'$delete_ays href='" . get_delete_post_link( $post->ID, '', true ) . "'>" . __( 'Delete permanently' ) . '</a>';
    476476        }
    477477    }
Note: See TracChangeset for help on using the changeset viewer.