Completed
Push — master ( ef04cf...199149 )
by Mike
02:19
created
test-content.php 1 patch
Indentation   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -28,17 +28,17 @@  discard block
 block discarded – undo
28 28
  		return;
29 29
  	}
30 30
 
31
-    $class = str_replace( __NAMESPACE__ . '\\', '', $class );
31
+	$class = str_replace( __NAMESPACE__ . '\\', '', $class );
32 32
 
33 33
 
34 34
 	if ( 'Views' === $namespace[1] ){
35
-        $class = strtolower( preg_replace( '/(?<!^)([A-Z])/', '/\1', $class ) );
36
-        $class = str_replace( '\\', '', $class );
37
-     	$file  = dirname( __FILE__ ) . '/' . $class . '.php';
38
-    } else {
39
-        $class = strtolower( preg_replace( '/(?<!^)([A-Z])/', '-\\1', $class ) );
40
-     	$file  = dirname( __FILE__ ) . '/includes/class-' . $class . '.php';
41
-    }
35
+		$class = strtolower( preg_replace( '/(?<!^)([A-Z])/', '/\1', $class ) );
36
+		$class = str_replace( '\\', '', $class );
37
+	 	$file  = dirname( __FILE__ ) . '/' . $class . '.php';
38
+	} else {
39
+		$class = strtolower( preg_replace( '/(?<!^)([A-Z])/', '-\\1', $class ) );
40
+	 	$file  = dirname( __FILE__ ) . '/includes/class-' . $class . '.php';
41
+	}
42 42
 
43 43
  	if ( file_exists( $file ) ) {
44 44
  		require_once( $file );
@@ -76,8 +76,8 @@  discard block
 block discarded – undo
76 76
 
77 77
  // Register hook providers and views.
78 78
  plugin()->register_hooks( new AdminPage() )
79
-         ->register_views( new Views\Posts() )
80
-         ->register_views( new Views\Terms() )
79
+		 ->register_views( new Views\Posts() )
80
+		 ->register_views( new Views\Terms() )
81 81
 		 ->register_views( new Views\Various() );
82 82
 
83 83
 // Load textdomain hook
Please login to merge, or discard this patch.
includes/class-delete.php 1 patch
Indentation   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
 		$post_types = get_post_types( array( 'public' => true ), 'objects' );
26 26
 		foreach ( $post_types as $post_type ) :
27 27
 
28
-		    $this->delete_posts( $post_type->name, $echo );
28
+			$this->delete_posts( $post_type->name, $echo );
29 29
 
30 30
 		endforeach;
31 31
 
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
 		$taxonomies = get_taxonomies();
34 34
 		foreach ( $taxonomies as $tax ) :
35 35
 
36
-		    $this->delete_terms( $tax, $echo );
36
+			$this->delete_terms( $tax, $echo );
37 37
 
38 38
 		endforeach;
39 39
 
@@ -182,14 +182,14 @@  discard block
 block discarded – undo
182 182
 
183 183
 		// Query for our terms
184 184
 		$args = array(
185
-		    'hide_empty' => false,
186
-		    'meta_query' => array(
187
-		        array(
188
-		           'key'       => 'evans_test_content',
189
-		           'value'     => '__test__',
190
-		           'compare'   => '='
191
-		        )
192
-		    )
185
+			'hide_empty' => false,
186
+			'meta_query' => array(
187
+				array(
188
+				   'key'       => 'evans_test_content',
189
+				   'value'     => '__test__',
190
+				   'compare'   => '='
191
+				)
192
+			)
193 193
 		);
194 194
 
195 195
 		$terms = get_terms( $slug, $args );
Please login to merge, or discard this patch.
includes/class-test-content.php 1 patch
Indentation   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -417,29 +417,29 @@  discard block
 block discarded – undo
417 417
 		}
418 418
 
419 419
 		// Download the file
420
-	    $tmp = \download_url( $url );
420
+		$tmp = \download_url( $url );
421 421
 
422
-	    preg_match( '/[^\?]+\.(jpg|JPG|jpe|JPE|jpeg|JPEG|gif|GIF|png|PNG)/', $url, $matches );
422
+		preg_match( '/[^\?]+\.(jpg|JPG|jpe|JPE|jpeg|JPEG|gif|GIF|png|PNG)/', $url, $matches );
423 423
 
424
-        $file_array['name'] = basename( $matches[0] );
425
-        $file_array['tmp_name'] = $tmp;
424
+		$file_array['name'] = basename( $matches[0] );
425
+		$file_array['tmp_name'] = $tmp;
426 426
 
427
-	    // Check for download errors
428
-	    if ( is_wp_error( $tmp ) ) {
429
-	        unlink( $file_array[ 'tmp_name' ] );
430
-	        error_log( $tmp->get_error_message() );
431
-	    }
427
+		// Check for download errors
428
+		if ( is_wp_error( $tmp ) ) {
429
+			unlink( $file_array[ 'tmp_name' ] );
430
+			error_log( $tmp->get_error_message() );
431
+		}
432 432
 
433 433
 		// Pull the image into the media library
434
-	    $image_id = media_handle_sideload( $file_array, $post_id );
434
+		$image_id = media_handle_sideload( $file_array, $post_id );
435 435
 
436
-	    // Check for handle sideload errors.
437
-	    if ( is_wp_error( $image_id ) ) {
438
-	        unlink( $file_array['tmp_name'] );
439
-	        error_log( $image_id->get_error_message() );
440
-	    }
436
+		// Check for handle sideload errors.
437
+		if ( is_wp_error( $image_id ) ) {
438
+			unlink( $file_array['tmp_name'] );
439
+			error_log( $image_id->get_error_message() );
440
+		}
441 441
 
442
-	    return apply_filters( "tc_image_data", $image_id );
442
+		return apply_filters( "tc_image_data", $image_id );
443 443
 
444 444
 	}
445 445
 
@@ -462,9 +462,9 @@  discard block
 block discarded – undo
462 462
 
463 463
 		// If our cURL failed
464 464
 		if ( $curl_response === false ) {
465
-		    $info = curl_getinfo( $curl );
466
-		    curl_close( $curl );
467
-		    die( 'error occured during curl exec. Additional info: ' . var_export( $info ) );
465
+			$info = curl_getinfo( $curl );
466
+			curl_close( $curl );
467
+			die( 'error occured during curl exec. Additional info: ' . var_export( $info ) );
468 468
 		}
469 469
 
470 470
 		curl_close( $curl );
Please login to merge, or discard this patch.