From ce9388db9cca076e891af1ed8ee23b1af3f06b13 Mon Sep 17 00:00:00 2001 From: Miguel Torres <1233880+mmtr@users.noreply.github.com> Date: Wed, 15 Jan 2025 08:40:03 +0100 Subject: [PATCH] Remove duplicate views: Remove icons object (#41054) --- .../changelog/update-remove-duplicate-views-icons | 5 +++++ .../removed-calypso-screen-notice.tsx | 12 +----------- 2 files changed, 6 insertions(+), 11 deletions(-) create mode 100644 projects/packages/jetpack-mu-wpcom/changelog/update-remove-duplicate-views-icons diff --git a/projects/packages/jetpack-mu-wpcom/changelog/update-remove-duplicate-views-icons b/projects/packages/jetpack-mu-wpcom/changelog/update-remove-duplicate-views-icons new file mode 100644 index 0000000000000..fe546ed5c4e84 --- /dev/null +++ b/projects/packages/jetpack-mu-wpcom/changelog/update-remove-duplicate-views-icons @@ -0,0 +1,5 @@ +Significance: patch +Type: changed +Comment: Removed no longer used code + + diff --git a/projects/packages/jetpack-mu-wpcom/src/features/wpcom-admin-interface/removed-calypso-screen-notice.tsx b/projects/packages/jetpack-mu-wpcom/src/features/wpcom-admin-interface/removed-calypso-screen-notice.tsx index e66adc61a947b..7b4f279d40e9f 100644 --- a/projects/packages/jetpack-mu-wpcom/src/features/wpcom-admin-interface/removed-calypso-screen-notice.tsx +++ b/projects/packages/jetpack-mu-wpcom/src/features/wpcom-admin-interface/removed-calypso-screen-notice.tsx @@ -146,17 +146,7 @@ const Notice = () => { }, }; - const icons = { - 'edit.php': verse, - 'edit.php?post_type=page': pages, - 'edit.php?post_type=jetpack-portfolio': archive, - 'edit.php?post_type=jetpack-testimonial': commentContent, - 'edit-comments.php': postComments, - 'edit-tags.php?taxonomy=category': category, - 'edit-tags.php?taxonomy=post_tag': tag, - }; - - if ( ! Object.keys( icons ).includes( removedCalypsoScreenNoticeConfig.screen ) ) { + if ( ! Object.keys( config ).includes( removedCalypsoScreenNoticeConfig.screen ) ) { return null; }