define_constants(); $this->load_files(); } /** * Define webhook module constants. */ private function define_constants() { define( 'CARTFLOWS_WEBHOOK_DIR', plugin_dir_path( __FILE__ ) ); } /** * Load module files. */ private function load_files() { include_once CARTFLOWS_WEBHOOK_DIR . 'classes/class-cartflows-webhook-manager.php'; include_once CARTFLOWS_WEBHOOK_DIR . 'classes/class-cartflows-webhook-payload.php'; include_once CARTFLOWS_WEBHOOK_DIR . 'classes/class-cartflows-webhook-dispatcher.php'; include_once CARTFLOWS_WEBHOOK_DIR . 'classes/class-cartflows-webhook-events.php'; // Instantiate dispatcher so AS hook is always registered. Cartflows_Webhook_Dispatcher::get_instance(); } } Cartflows_Webhook_Loader::get_instance(); }