PluginProbe
The Innovative Form Builder – IvyForms / 1.5
The Innovative Form Builder – IvyForms v1.5
1.5.1 1.5 1.4.1 1.4 trunk 0.1.2 0.2 0.2.1 0.3 0.3.1 0.4 0.5 0.6 0.6.1 0.6.1-backup 0.6.1.1 0.7 0.8 0.8.1 0.8.2 0.9 0.9.1 1.0 1.1 1.1.1 All 27 releases
← All changes | backend/src/Services/InstallActions/ActivationMultisite.php +3 -4 0.3 → 1.5 View file →
@@ -5,12 +5,9 @@
5 5 */
6 6
7 7 namespace IvyForms\Services\InstallActions;
8 8
9 -// phpcs:disable PSR1.Files.SideEffects
10 -if (!defined('ABSPATH')) {
11 - exit; // Exit if accessed directly
12 -}
9 +use IvyForms\Common\Exceptions\InvalidArgumentException;
13 10
14 11 /**
15 12 * Class ActivationMultisite
16 13 *
@@ -19,8 +16,9 @@
19 16 class ActivationMultisite
20 17 {
21 18 /**
22 19 * Activate the plugin for every sub-site separately
20 + * @throws InvalidArgumentException
23 21 */
24 22 public static function init(): void
25 23 {
26 24 global $wpdb;
@@ -35,8 +33,9 @@
35 33 foreach ($siteIds as $siteId) {
36 34 switch_to_blog($siteId);
37 35 // Create database table if not exists
38 36 ActivationDatabaseHook::init();
37 + ActivationCapabilitiesHook::ensureAdministratorCaps();
39 38 }
40 39 // Returns to current blog
41 40 switch_to_blog($oldSite);
42 41 }