PluginProbe
SureForms – Contact Form Builder, AI Forms, Payment Form, Survey & Quiz / 1.2.2
SureForms – Contact Form Builder, AI Forms, Payment Form, Survey & Quiz v1.2.2
2.12.6 2.12.5 2.12.4 2.12.3 2.12.2 2.12.1 2.12.0 2.11.1 2.11.0 2.10.1 2.10.0 2.9.1 2.9.0 2.8.2 2.8.1 2.7.0 2.7.1 2.8.0 trunk 0.0.10 0.0.11 0.0.12 0.0.13 0.0.2 0.0.3 All 96 releases
← All changes | plugin-loader.php +12 -0 1.2.11.2.2 View file →
@@ -29,8 +29,10 @@
29 29 use SRFM\Inc\Global_Settings\Email_Summary;
30 30 use SRFM\Inc\Global_Settings\Global_Settings;
31 31 use SRFM\Inc\Gutenberg_Hooks;
32 32 use SRFM\Inc\Helper;
33 +use SRFM\Inc\Lib\SRFM_Nps_Survey;
34 +use SRFM\Inc\Nps_Notice;
33 35 use SRFM\Inc\Page_Builders\Page_Builders;
34 36 use SRFM\Inc\Post_Types;
35 37 use SRFM\Inc\Rest_Api;
36 38 use SRFM\Inc\Single_Form_Settings\Compliance_Settings;
@@ -286,8 +288,18 @@
286 288 AI_Helper::get_instance();
287 289 AI_Auth::get_instance();
288 290 Updater::get_instance();
289 291 DatabaseRegister::init();
292 +
293 + /**
294 + * Required to add the if check for the class existence to resolve phpstan error,
295 + * as the phpstan configuration ignores the inc/lib directory which gives error
296 + * unknown class.
297 + */
298 + if ( class_exists( 'SRFM\Inc\Lib\SRFM_Nps_Survey' ) && ! apply_filters( 'srfm_disable_nps_survey', true ) ) {
299 + SRFM_Nps_Survey::get_instance(); // Inits the NPS Survey class for which inits the NPS Survey plugin.
300 + Nps_Notice::get_instance(); // Responsible for displaying the NPS Survey: keeping the line out of the check will also work.
301 + }
290 302
291 303 /**
292 304 * Load core files necessary for the Spectra block.
293 305 * This method is called in the Spectra block loader to ensure core files are loaded during the 'plugins_loaded' action.