admin = new Send4_Admin(); $this->admin->boot(); Send4_Minimum_Version::boot(); } if ( defined( 'WP_CLI' ) && WP_CLI ) { Send4_Cli::register(); } } /** * Once every plugin is loaded we know which form plugins are present. * * Hooks are registered on every request, not just admin or front end: * Contact Form 7 and WPForms both submit through REST or admin-ajax. * * @return void */ public function on_plugins_loaded() { Send4_Installer::maybe_upgrade(); Send4_Adapters::register_hooks(); Send4_Adapters::register_validation(); } /** * Scheduled events, once translations can be loaded. * * There is no load_plugin_textdomain() call: since WordPress 4.6 the * `send4` domain is loaded just in time from the language packs * WordPress.org builds, and the plugin ships no .mo files of its own, so * the call loaded nothing. Plugin Check flags it for a listed plugin * (#1531). * * @return void */ public function on_init() { // On init, deliberately: scheduling runs the `cron_schedules` filter, // whose display names are translated, and translating before init // earns a `_load_textdomain_just_in_time` notice. Send4_Installer::ensure_events(); } }