Completed
Push — develop ( c1cebe...93b04b )
by Paul
01:58
created
src/Container.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -185,8 +185,7 @@
 block discarded – undo
185 185
 	{
186 186
 		try {
187 187
 			return $this->make( $parameter->getClass()->name );
188
-		}
189
-		catch( BindingResolutionException $e ) {
188
+		} catch( BindingResolutionException $e ) {
190 189
 			if( $parameter->isOptional() ) {
191 190
 				return $parameter->getDefaultValue();
192 191
 			}
Please login to merge, or discard this patch.
src/Helpers/Theme.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -72,7 +72,9 @@
 block discarded – undo
72 72
 	public function pageTitle()
73 73
 	{
74 74
 		foreach( ['is_404', 'is_archive', 'is_home', 'is_page', 'is_search'] as $bool ) {
75
-			if( !$bool() )continue;
75
+			if( !$bool() ) {
76
+				continue;
77
+			}
76 78
 			$method = sprintf( 'get%sTitle', ucfirst( str_replace( 'is_', '', $bool )));
77 79
 			return $this->$method();
78 80
 		}
Please login to merge, or discard this patch.
src/Helpers/Development.php 1 patch
Braces   +4 added lines, -3 removed lines patch added patch discarded remove patch
@@ -43,8 +43,7 @@  discard block
 block discarded – undo
43 43
 			printf( '<div class="print__r"><pre>%s</pre></div>',
44 44
 				htmlspecialchars( print_r( func_get_arg(0), true ), ENT_QUOTES, 'UTF-8' )
45 45
 			);
46
-		}
47
-		else if( $args > 1 ) {
46
+		} else if( $args > 1 ) {
48 47
 			echo '<div class="print__r_group">';
49 48
 			foreach( func_get_args() as $value ) {
50 49
 				$this->print( $value );
@@ -56,7 +55,9 @@  discard block
 block discarded – undo
56 55
 	public function printFiltersFor( $hook = '' )
57 56
 	{
58 57
 		global $wp_filter;
59
-		if( empty( $hook ) || !isset( $wp_filter[$hook] ))return;
58
+		if( empty( $hook ) || !isset( $wp_filter[$hook] )) {
59
+			return;
60
+		}
60 61
 		$this->print( $wp_filter[ $hook ] );
61 62
 	}
62 63
 
Please login to merge, or discard this patch.
src/Helpers/Render.php 1 patch
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -33,7 +33,9 @@  discard block
 block discarded – undo
33 33
 	{
34 34
 		$post = get_post( $postId );
35 35
 
36
-		if( !$postId || !$post )return;
36
+		if( !$postId || !$post ) {
37
+			return;
38
+		}
37 39
 		if( !$title ) {
38 40
 			$title = $post->post_title;
39 41
 		}
@@ -71,7 +73,9 @@  discard block
 block discarded – undo
71 73
 			? $this->postmeta->get( $metaKey )
72 74
 			: $this->theme->pageTitle();
73 75
 
74
-		if( !$value )return;
76
+		if( !$value ) {
77
+			return;
78
+		}
75 79
 
76 80
 		$this->utility->printTag( $tag, wp_strip_all_tags( $value ), $attributes );
77 81
 	}
Please login to merge, or discard this patch.
src/Gallery.php 1 patch
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -65,7 +65,9 @@  discard block
 block discarded – undo
65 65
 	{
66 66
 		$image = $this->image->get( $attachment->ID )->image;
67 67
 
68
-		if( !$image )return;
68
+		if( !$image ) {
69
+			return;
70
+		}
69 71
 		return sprintf(
70 72
 			'<figure class="gallery-image" data-w="%s" data-h="%s" data-ps=\'%s\' itemprop="associatedMedia" itemscope itemtype="http://schema.org/ImageObject">' .
71 73
 				'%s<figcaption itemprop="caption description">' .
@@ -86,7 +88,9 @@  discard block
 block discarded – undo
86 88
 	 */
87 89
 	public function renderPagination()
88 90
 	{
89
-		if( !$this->args['pagination'] )return;
91
+		if( !$this->args['pagination'] ) {
92
+			return;
93
+		}
90 94
 		return paginate_links([
91 95
 			'before_page_number' => '<span class="screen-reader-text">' . __( 'Page', 'castor' ) . ' </span>',
92 96
 			'current'            => $this->gallery->query['paged'],
Please login to merge, or discard this patch.
src/Helpers/PostMeta.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,9 @@
 block discarded – undo
6 6
 {
7 7
 	public function get( $metaKey, array $args = [] )
8 8
 	{
9
-		if( empty( $metaKey ))return;
9
+		if( empty( $metaKey )) {
10
+			return;
11
+		}
10 12
 
11 13
 		$args = $this->normalize( $args );
12 14
 		$metaKey = $this->buildMetaKey( $metaKey, $args['prefix'] );
Please login to merge, or discard this patch.
src/Image.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -59,7 +59,9 @@
 block discarded – undo
59 59
 
60 60
 		$attachment = get_post( $attachmentId );
61 61
 
62
-		if( is_null( $attachment ) || $attachment->post_type != 'attachment' )return;
62
+		if( is_null( $attachment ) || $attachment->post_type != 'attachment' ) {
63
+			return;
64
+		}
63 65
 
64 66
 		return $attachment->ID;
65 67
 	}
Please login to merge, or discard this patch.
src/Video.php 1 patch
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,7 +41,9 @@  discard block
 block discarded – undo
41 41
 
42 42
 	public function render()
43 43
 	{
44
-		if( !isset( $this->video->html ))return;
44
+		if( !isset( $this->video->html )) {
45
+			return;
46
+		}
45 47
 		return sprintf(
46 48
 			'<div class="video embed">%s%s</div>',
47 49
 			$this->renderScreenshot(),
@@ -114,7 +116,9 @@  discard block
 block discarded – undo
114 116
 
115 117
 		foreach( $this->args as $key => $value ) {
116 118
 			$method = $this->utility->buildMethodName( $key, 'set' );
117
-			if( !method_exists( $this, $method ))continue;
119
+			if( !method_exists( $this, $method )) {
120
+				continue;
121
+			}
118 122
 			call_user_func([ $this, $method ], $value );
119 123
 		}
120 124
 		return $this->args;
Please login to merge, or discard this patch.
src/Oembed.php 1 patch
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -37,8 +37,12 @@
 block discarded – undo
37 37
 			'width'  => 1280,
38 38
 			'height' => 1280,
39 39
 		]);
40
-		if( $request === false )return;
41
-		if( !empty( $args['embed_type'] ) && $args['embed_type'] != $request->type )return;
40
+		if( $request === false ) {
41
+			return;
42
+		}
43
+		if( !empty( $args['embed_type'] ) && $args['embed_type'] != $request->type ) {
44
+			return;
45
+		}
42 46
 		return $this->modifyRequest( $request, $args );
43 47
 	}
44 48
 
Please login to merge, or discard this patch.