@@ 209-213 (lines=5) @@ | ||
206 | ||
207 | $result = activate_plugin( $plugin, '', $this->network_wide ); |
|
208 | ||
209 | if ( is_wp_error( $result ) ) { |
|
210 | $this->log[ $plugin ]['error'] = $result->get_error_messages(); |
|
211 | $has_errors = true; |
|
212 | continue; |
|
213 | } |
|
214 | ||
215 | $success = Jetpack::is_plugin_active( $plugin ); |
|
216 | if ( $success && $this->network_wide ) { |
|
@@ 220-224 (lines=5) @@ | ||
217 | $success &= is_plugin_active_for_network( $plugin ); |
|
218 | } |
|
219 | ||
220 | if ( ! $success ) { |
|
221 | $this->log[ $plugin ]['error'] = $result->get_error_messages; |
|
222 | $has_errors = true; |
|
223 | continue; |
|
224 | } |
|
225 | $this->log[ $plugin ][] = __( 'Plugin activated.', 'jetpack' ); |
|
226 | } |
|
227 |
@@ 118-122 (lines=5) @@ | ||
115 | ||
116 | $result = activate_plugin( $plugin, '', $this->network_wide ); |
|
117 | ||
118 | if ( is_wp_error( $result ) ) { |
|
119 | $this->log[ $plugin ]['error'] = $result->get_error_messages(); |
|
120 | $has_errors = true; |
|
121 | continue; |
|
122 | } |
|
123 | ||
124 | $success = Jetpack::is_plugin_active( $plugin ); |
|
125 | if ( $success && $this->network_wide ) { |