Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Gravity Perks // GP Better User Activation // Enable Editor on Activation Page
<?php
/**
* Gravity Perks // GP Better User Activation // Enable Editor on Activation Page
* http://gravitywiz.com/documentionat/gravity-forms-better-user-activation/
*/
add_action( 'init', function() {
if ( is_callable( 'gp_better_user_activation' ) ) {
remove_action( 'admin_head', array( gp_better_user_activation(), 'remove_default_content_editor' ) );
}
} );
@madrid1979
Copy link

madrid1979 commented Feb 3, 2022

Recommend adding a function_exists check prior to the action in case you deactivate the plugin for any reason.
ex:
if ( function_exists('gp_better_user_activation') ){ add_action( 'init', function() { remove_action( 'admin_head', array( gp_better_user_activation(), 'remove_default_content_editor' ) ); }); }

@spivurno
Copy link
Author

spivurno commented Feb 4, 2022

Agreed, @madrid1979! I implemented a change based on your feedback. 🙏

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