Skip to content

Instantly share code, notes, and snippets.

@gschoppe
Forked from senlin/classic-editor-addon.php
Last active November 2, 2018 19:47
Show Gist options
  • Star 5 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gschoppe/ce88a7821764ef11803a5c64350078b6 to your computer and use it in GitHub Desktop.
Save gschoppe/ce88a7821764ef11803a5c64350078b6 to your computer and use it in GitHub Desktop.
// moved to https://wordpress.org/plugins/classic-editor-addon/
@senlin
Copy link

senlin commented Jun 10, 2018

Hi @gschoppe Greg,

I came to realise that the filter of the plugin_action_links with the classic_editor_addon_remove_settings_link function does not work.

To make it work, the filter needs to be replaced with an action:
add_action( 'plugins_loaded', 'classic_editor_addon_remove_settings_link' );

And the function itself can be simplified by:

function classic_editor_addon_remove_settings_link() {
	remove_filter( 'plugin_action_links', 'classic_editor_add_settings_link' );
}

You can see, the changes also in my original gist (updated of course with your changes).

What do you think about releasing this together as a plugin in the WP Plugin Repo?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment