ybe just ignore all of those when the user can't use custom fonts?
add_filter( 'post_row_actions', [ $this, 'post_row_actions' ], 10, 2 );
add_filter( 'manage_' . self::CPT . '_posts_columns', [ $this, 'manage_columns' ], 100 );
add_action( 'save_post_' . self::CPT, [ $this, 'save_post_meta' ], 10, 3 );
add_action( 'save_post_' . self::CPT, [ $this, 'clear_fonts_list' ], 100 );
add_filter( 'elementor/fonts/groups', [ $this, 'register_fonts_groups' ] );
add_filter( 'elementor/fonts/additional_fonts', [ $this, 'register_fonts_in_control' ] );
add_filter( 'elementor/finder/categories', [ $this, 'add_finder_item' ] );
add_action( 'elementor/css-file/post/parse', [ $this, 'enqueue_fonts' ] );
add_action( 'elementor/css-file/global/parse', [ $this, 'enqueue_fonts' ] );
add_filter( 'post_updated_messages', [ $this, 'post_updated_messages' ] );
add_filter( 'enter_title_here', [ $this, 'update_enter_title_here' ], 10, 2 );
// Ajax.
add_action( 'elementor/ajax/register_actions', [ $this, 'register_ajax_actions' ] );
/**
* Elementor fonts manager loaded.
*
* Fires after the fonts manager was fully loaded and instantiated.
*
* @since 2.0.0
*
* @param Fonts_Manager $this An instance of fonts manager.
*/
do_action( 'elementor_pro/fonts_manager_loaded', $this );
}
/**
* Fonts_Manager constructor.
*/
public function __construct() {
$this->actions();
$this->add_font_type( 'custom', new Fonts\Custom_Fonts() );
$this->add_font_type( 'typekit', new Fonts\Typekit_Fonts() );
}
}
Fatal error: Uncaught Error: Class 'ElementorPro\Modules\AssetsManager\AssetTypes\Fonts_Manager' not found in /home/sportuga/public_html/wp-content/plugins/elementor-pro/modules/assets-manager/module.php:48
Stack trace:
#0 /home/sportuga/public_html/wp-content/plugins/elementor/core/base/module.php(85): ElementorPro\Modules\AssetsManager\Module->__construct()
#1 /home/sportuga/public_html/wp-content/plugins/elementor-pro/core/modules-manager.php(93): Elementor\Core\Base\Module::instance()
#2 /home/sportuga/public_html/wp-content/plugins/elementor-pro/plugin.php(375): ElementorPro\Core\Modules_Manager->__construct()
#3 /home/sportuga/public_html/wp-includes/class-wp-hook.php(324): ElementorPro\Plugin->on_elementor_init('')
#4 /home/sportuga/public_html/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters(NULL, Array)
#5 /home/sportuga/public_html/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
#6 /home/sportuga/public_html/wp-content/plugins/elementor/includes/plugin.php(658): do_action('elementor/init')
#7 /h in /home/sportuga/public_html/wp-content/plugins/elementor-pro/modules/assets-manager/module.php on line 48