The init
hook have no parameters! The hook is fired after WordPress has finished loading but before any headers are sent. You can alternate use the closure function since php5.6 to add a param on this hook.
From the core, see the file on github.
/**
* Fires after WordPress has finished loading but before any headers are sent.
*
* Most of WP is loaded at this stage, and the user is authenticated. WP continues
* to load on the {@see 'init'} hook that follows (e.g. widgets), and many plugins instantiate
* themselves on it for all sorts of reasons (e.g. they need a user, a taxonomy, etc.).
*
* If you wish to plug an action once WP is loaded, use the {@see 'wp_loaded'} hook below.
*
* @since 1.5.0
*/
do_action( 'init' );
If you need to remove the editor, then is it not necessary to use a parameter no the hook. A simple remove is enough.
//remove default wysiwyg editor
add_action( 'init', function() {
remove_post_type_support( 'post', 'editor' );
}, 100);
In your enhanced comment, see this example to add a param with the help of closures - use.
//remove default wysiwyg editor
add_action( 'init', function() use ($pt_name) {
remove_post_type_support( $pt_name, 'editor' );
}, 100);