Completed
Push — fix/flickr-shortcode ( 3e5712...02d728 )
by
unknown
24:33 queued 14:33
created

Jetpack_Wizard   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 20
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 0
Metric Value
dl 0
loc 20
rs 10
c 0
b 0
f 0
wmc 4
lcom 0
cbo 2

1 Method

Rating   Name   Duplication   Size   Complexity  
A can_be_displayed() 0 13 4
1
<?php
2
/**
3
 * Displays the first page of the Wizard in a banner form
4
 *
5
 * @package Jetpack
6
 */
7
8
/**
9
 * Jetpack_Wizard class
10
 */
11
class Jetpack_Wizard {
12
	/**
13
	 * Can the Wizard be displayed?
14
	 *
15
	 * @return bool
16
	 */
17
	public static function can_be_displayed() {
18
		/**
19
		 * Determines if the Setup Wizard is displayed or not.
20
		 *
21
		 * @since 8.5.0
22
		 *
23
		 * @param array $jetpack_show_setup_wizard If true, the Setup Wizard will be displayed. Otherwise it will not display.
24
		 */
25
		return apply_filters( 'jetpack_show_setup_wizard', false )
26
			&& Jetpack::is_active()
27
			&& current_user_can( 'jetpack_manage_modules' )
28
			&& 'completed' !== Jetpack_Options::get_option( 'setup_wizard_status' );
29
	}
30
}
31