PluginProbe
Fluent Forms – Customizable Contact Forms, Survey, Quiz, & Conversational Form Builder / trunk
Fluent Forms – Customizable Contact Forms, Survey, Quiz, & Conversational Form Builder vtrunk
6.2.15 6.2.14 6.2.13 6.2.12 6.2.10 6.2.11 6.2.9 6.2.8 6.2.7 6.2.6 6.2.5 6.2.4 6.2.3 6.2.2 3.6.22 3.6.31 3.6.40 3.6.41 3.6.42 3.6.50 3.6.51 3.6.60 3.6.61 3.6.62 3.6.64 All 197 releases
← All changes | app/Modules/AddOnModule.php +17 -7 6.2.9 → trunk View file →
@@ -65,8 +65,24 @@
65 65 public function showFluentAddOns()
66 66 {
67 67 wp_enqueue_script('fluentform-modules');
68 68
69 + $addOns = $this->getRegisteredAddOns();
70 +
71 + wp_localize_script('fluentform-modules', 'fluent_addon_modules', [
72 + 'addons' => $addOns,
73 + 'has_pro' => defined('FLUENTFORMPRO'),
74 + 'addOnModule_str' => TranslationString::getAddOnModuleI18n(),
75 + ]);
76 +
77 + wpFluentForm('view')->render('admin.addons.list', []);
78 + }
79 +
80 + /**
81 + * The registry the Add-on Modules screen renders from, so the status writer can validate against the same source.
82 + */
83 + public function getRegisteredAddOns()
84 + {
69 85 $addOns = apply_filters_deprecated(
70 86 'fluentform_global_addons',
71 87 [
72 88 [],
@@ -89,15 +105,9 @@
89 105 if (!defined('FLUENTFORMPRO')) {
90 106 $addOns = array_merge($addOns, $this->getPremiumAddOns());
91 107 }
92 108
93 - wp_localize_script('fluentform-modules', 'fluent_addon_modules', [
94 - 'addons' => $addOns,
95 - 'has_pro' => defined('FLUENTFORMPRO'),
96 - 'addOnModule_str' => TranslationString::getAddOnModuleI18n(),
97 - ]);
98 -
99 - wpFluentForm('view')->render('admin.addons.list', []);
109 + return $addOns;
100 110 }
101 111
102 112 public function getPremiumAddOns()
103 113 {