diff --git a/src/wp-includes/link-template.php b/src/wp-includes/link-template.php index 9e654aaaeb..519e307764 100644 --- a/src/wp-includes/link-template.php +++ b/src/wp-includes/link-template.php @@ -452,6 +452,8 @@ function get_attachment_link( $post = null, $leavename = false ) { * Filters the permalink for an attachment. * * @since 2.0.0 + * @since 5.6.0 Providing an empty string will now disable + * the view attachment page link on the media modal. * * @param string $link The attachment's permalink. * @param int $post_id Attachment ID. diff --git a/src/wp-includes/media-template.php b/src/wp-includes/media-template.php index c2b87b28af..9908843b98 100644 --- a/src/wp-includes/media-template.php +++ b/src/wp-includes/media-template.php @@ -514,11 +514,19 @@ function wp_print_media_templates() {