Passed
Push — master ( 0dd98d...32d871 )
by Paul
05:17
created
autoload.php 1 patch
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -15,9 +15,13 @@
 block discarded – undo
15 15
 	];
16 16
 	foreach( $namespaces as $prefix => $base_dir ) {
17 17
 		$len = strlen( $prefix );
18
-		if( strncmp( $prefix, $className, $len ) !== 0 )continue;
18
+		if( strncmp( $prefix, $className, $len ) !== 0 ) {
19
+			continue;
20
+		}
19 21
 		$file = $base_dir.str_replace( '\\', '/', substr( $className, $len )).'.php';
20
-		if( !file_exists( $file ))continue;
22
+		if( !file_exists( $file )) {
23
+			continue;
24
+		}
21 25
 		require $file;
22 26
 		break;
23 27
 	}
Please login to merge, or discard this patch.
site-reviews.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,9 @@
 block discarded – undo
21 21
 if( !class_exists( 'GL_Plugin_Check_v1' )) {
22 22
 	require_once __DIR__.'/activate.php';
23 23
 }
24
-if( GL_Plugin_Check_v1::shouldDeactivate( __FILE__, array( 'wordpress' => '4.7.0' )))return;
24
+if( GL_Plugin_Check_v1::shouldDeactivate( __FILE__, array( 'wordpress' => '4.7.0' ))) {
25
+	return;
26
+}
25 27
 
26 28
 require_once __DIR__.'/autoload.php';
27 29
 require_once __DIR__.'/helpers.php';
Please login to merge, or discard this patch.
plugin/Handlers/RegisterPostType.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -11,7 +11,9 @@
 block discarded – undo
11 11
 	 */
12 12
 	public function handle( Command $command )
13 13
 	{
14
-		if( in_array( $command->postType, get_post_types( ['_builtin' => true] )))return;
14
+		if( in_array( $command->postType, get_post_types( ['_builtin' => true] ))) {
15
+			return;
16
+		}
15 17
 		register_post_type( $command->postType, $command->args );
16 18
 		glsr()->postTypeColumns = wp_parse_args( glsr()->postTypeColumns, [
17 19
 			$command->postType => $command->columns,
Please login to merge, or discard this patch.
plugin/Handlers/RegisterTaxonomy.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -57,7 +57,9 @@
 block discarded – undo
57 57
 		global $wp_query;
58 58
 		if( !is_object_in_taxonomy( get_current_screen()->post_type, Application::TAXONOMY )
59 59
 			|| apply_filters( 'site-reviews/disable/filter/category', false )
60
-		)return;
60
+		) {
61
+			return;
62
+		}
61 63
 		printf( '<label class="screen-reader-text" for="%s">%s</label>', Application::TAXONOMY, __( 'Filter by category', 'site-reviews' ));
62 64
 		$selected = isset( $wp_query->query[Application::TAXONOMY] )
63 65
 			? $wp_query->query[Application::TAXONOMY]
Please login to merge, or discard this patch.
plugin/Controllers/MainController.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,9 @@
 block discarded – undo
19 19
 	 */
20 20
 	public function registerPostType()
21 21
 	{
22
-		if( !glsr()->hasPermission() )return;
22
+		if( !glsr()->hasPermission() ) {
23
+			return;
24
+		}
23 25
 		$command = new RegisterPostType([
24 26
 			'capabilities'=> ['create_posts' => 'create_'.Application::POST_TYPE],
25 27
 			'columns' => [
Please login to merge, or discard this patch.
plugin/Controllers/MenuController.php 1 patch
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -20,7 +20,9 @@  discard block
 block discarded – undo
20 20
 	{
21 21
 		global $menu, $typenow;
22 22
 		foreach( $menu as $key => $value ) {
23
-			if( !isset( $value[2] ) || $value[2] != 'edit.php?post_type='.Application::POST_TYPE )continue;
23
+			if( !isset( $value[2] ) || $value[2] != 'edit.php?post_type='.Application::POST_TYPE ) {
24
+				continue;
25
+			}
24 26
 			$postCount = wp_count_posts( Application::POST_TYPE );
25 27
 			$pendingCount = glsr( Builder::class )->span( number_format_i18n( $postCount->pending ), [
26 28
 				'class' => 'pending-count',
@@ -52,7 +54,9 @@  discard block
 block discarded – undo
52 54
 		foreach( $pages as $slug => $title ) {
53 55
 			$method = glsr( Helper::class )->buildMethodName( 'render-'.$slug.'-menu' );
54 56
 			$callback = apply_filters( 'site-reviews/addon/submenu/callback', [$this, $method], $slug );
55
-			if( !is_callable( $callback ))continue;
57
+			if( !is_callable( $callback )) {
58
+				continue;
59
+			}
56 60
 			add_submenu_page( 'edit.php?post_type='.Application::POST_TYPE, $title, $title, Application::CAPABILITY, $slug, $callback );
57 61
 		}
58 62
 	}
Please login to merge, or discard this patch.
plugin/Helper.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -166,7 +166,9 @@
 block discarded – undo
166 166
 	{
167 167
 		$result = [];
168 168
 		foreach( $array as $key => $value ) {
169
-			if( !$value )continue;
169
+			if( !$value ) {
170
+				continue;
171
+			}
170 172
 			$result[$key] = is_array( $value )
171 173
 				? $this->removeEmptyArrayValues( $value )
172 174
 				: $value;
Please login to merge, or discard this patch.
plugin/Application.php 1 patch
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -153,7 +153,9 @@  discard block
 block discarded – undo
153 153
 	 */
154 154
 	public function scheduleCronJob()
155 155
 	{
156
-		if( wp_next_scheduled( static::CRON_EVENT ))return;
156
+		if( wp_next_scheduled( static::CRON_EVENT )) {
157
+			return;
158
+		}
157 159
 		wp_schedule_event( time(), 'twicedaily', static::CRON_EVENT );
158 160
 	}
159 161
 
@@ -184,7 +186,9 @@  discard block
 block discarded – undo
184 186
 			|| !in_array( plugin_basename( $this->file ), $data['plugins'] )
185 187
 			|| $data['action'] != 'update'
186 188
 			|| $data['type'] != 'plugin'
187
-		)return;
189
+		) {
190
+			return;
191
+		}
188 192
 		$this->upgrade();
189 193
 	}
190 194
 
Please login to merge, or discard this patch.
plugin/Shortcodes/Shortcode.php 1 patch
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -76,7 +76,9 @@  discard block
 block discarded – undo
76 76
 		$args = shortcode_atts( $this->getDefaults(), wp_parse_args( $args ));
77 77
 		array_walk( $args, function( &$value, $key ) {
78 78
 			$methodName = glsr( Helper::class )->buildMethodName( $key, 'normalize' );
79
-			if( !method_exists( $this, $methodName ))return;
79
+			if( !method_exists( $this, $methodName )) {
80
+				return;
81
+			}
80 82
 			$value = $this->$methodName( $value );
81 83
 		});
82 84
 		return $this->sanitize( $args );
@@ -141,7 +143,9 @@  discard block
 block discarded – undo
141 143
 		$defaults = array_pad( $defaults, Rating::MAX_RATING, '' );
142 144
 		$labels = array_map( 'trim', explode( ',', $labels ));
143 145
 		foreach( $defaults as $i => $label ) {
144
-			if( empty( $labels[$i] ))continue;
146
+			if( empty( $labels[$i] )) {
147
+				continue;
148
+			}
145 149
 			$defaults[$i] = $labels[$i];
146 150
 		}
147 151
 		return array_combine( range( Rating::MAX_RATING, 1 ), $defaults );
Please login to merge, or discard this patch.