This commit is contained in:
Mario Voigt 2023-04-12 02:02:18 +02:00
parent ff31aff5c2
commit a936333a97

View File

@ -201,13 +201,17 @@ function amp_admin_sublinks( $links ) {
} else {
if ( amp_have_capability( ampCap::ManagePlugins ) !== true) {
if(!empty($links['plugins'])) {
foreach( $links['plugins'] as $link => $ar ) {
if(!in_array($link, $amp_allowed_plugin_pages) )
unset($links['plugins'][$link]);
}
}
}
if(!empty($links['plugins'])) {
sort($links['plugins']);
}
}
return $links;
}