Passed
Pull Request — master (#424)
by Chris
02:20
created
page-templates/template-archives.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@  discard block
 block discarded – undo
12 12
 
13 13
 <?php lsx_content_wrap_before(); ?>
14 14
 
15
-<div id="primary" class="content-area <?php echo esc_attr( lsx_main_class() ); ?>">
15
+<div id="primary" class="content-area <?php echo esc_attr(lsx_main_class()); ?>">
16 16
 
17 17
 	<?php lsx_content_before(); ?>
18 18
 
@@ -20,10 +20,10 @@  discard block
 block discarded – undo
20 20
 
21 21
 		<?php lsx_content_top(); ?>
22 22
 
23
-		<?php if ( have_posts() ) : ?>
23
+		<?php if (have_posts()) : ?>
24 24
 
25 25
 			<?php
26
-			while ( have_posts() ) :
26
+			while (have_posts()) :
27 27
 				the_post();
28 28
 				?>
29 29
 
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
 					<?php lsx_entry_top(); ?>
35 35
 
36 36
 					<div class="entry-content">
37
-						<h2><?php esc_html_e( 'The Last 30 Posts', 'lsx' ); ?></h2>
37
+						<h2><?php esc_html_e('The Last 30 Posts', 'lsx'); ?></h2>
38 38
 
39 39
 						<ul>
40 40
 							<?php
@@ -45,16 +45,16 @@  discard block
 block discarded – undo
45 45
 								);
46 46
 							?>
47 47
 
48
-							<?php if ( $loop->have_posts() ) : ?>
48
+							<?php if ($loop->have_posts()) : ?>
49 49
 
50
-								<?php while ( $loop->have_posts() ) : ?>
50
+								<?php while ($loop->have_posts()) : ?>
51 51
 
52 52
 									<?php
53 53
 										$loop->the_post();
54 54
 										$loop->is_home = false;
55 55
 									?>
56 56
 
57
-									<li><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a> - <?php the_time( get_option( 'date_format' ) ); ?> - <?php echo esc_html( $post->comment_count ); ?> <?php esc_html_e( 'comments', 'lsx' ); ?></li>
57
+									<li><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a> - <?php the_time(get_option('date_format')); ?> - <?php echo esc_html($post->comment_count); ?> <?php esc_html_e('comments', 'lsx'); ?></li>
58 58
 
59 59
 								<?php endwhile; ?>
60 60
 
@@ -63,16 +63,16 @@  discard block
 block discarded – undo
63 63
 							<?php wp_reset_postdata(); ?>
64 64
 						</ul>
65 65
 
66
-						<h2><?php esc_html_e( 'Categories', 'lsx' ); ?></h2>
66
+						<h2><?php esc_html_e('Categories', 'lsx'); ?></h2>
67 67
 
68 68
 						<ul>
69
-							<?php wp_list_categories( 'title_li=&hierarchical=0&show_count=1' ); ?>
69
+							<?php wp_list_categories('title_li=&hierarchical=0&show_count=1'); ?>
70 70
 						</ul>
71 71
 
72
-						<h2><?php esc_html_e( 'Monthly Archives', 'lsx' ); ?></h2>
72
+						<h2><?php esc_html_e('Monthly Archives', 'lsx'); ?></h2>
73 73
 
74 74
 						<ul>
75
-							<?php wp_get_archives( 'type=monthly&show_post_count=1' ); ?>
75
+							<?php wp_get_archives('type=monthly&show_post_count=1'); ?>
76 76
 						</ul>
77 77
 					</div><!-- .entry-content -->
78 78
 
Please login to merge, or discard this patch.
partials/content-post.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -17,31 +17,31 @@
 block discarded – undo
17 17
 		<?php
18 18
 			the_content();
19 19
 
20
-			wp_link_pages( array(
20
+			wp_link_pages(array(
21 21
 				'before'      => '<div class="lsx-postnav-wrapper"><div class="lsx-postnav">',
22 22
 				'after'       => '</div></div>',
23 23
 				'link_before' => '<span>',
24 24
 				'link_after'  => '</span>',
25
-			) );
25
+			));
26 26
 		?>
27 27
 	</div><!-- .entry-content -->
28 28
 
29 29
 	<footer class="footer-meta clearfix">
30
-		<?php if ( has_tag() || class_exists( 'LSX_Sharing' ) || ( function_exists( 'sharing_display' ) || class_exists( 'Jetpack_Likes' ) ) ) : ?>
30
+		<?php if (has_tag() || class_exists('LSX_Sharing') || (function_exists('sharing_display') || class_exists('Jetpack_Likes'))) : ?>
31 31
 			<div class="post-tags-wrapper">
32 32
 				<?php lsx_content_post_tags(); ?>
33 33
 
34 34
 				<?php
35
-				if ( class_exists( 'LSX_Sharing' ) ) {
35
+				if (class_exists('LSX_Sharing')) {
36 36
 					lsx_content_sharing();
37 37
 				} else {
38
-					if ( function_exists( 'sharing_display' ) ) {
39
-						sharing_display( '', true );
38
+					if (function_exists('sharing_display')) {
39
+						sharing_display('', true);
40 40
 					}
41 41
 
42
-					if ( class_exists( 'Jetpack_Likes' ) ) {
42
+					if (class_exists('Jetpack_Likes')) {
43 43
 						$custom_likes = new Jetpack_Likes();
44
-						echo wp_kses_post( $custom_likes->post_likes( '' ) );
44
+						echo wp_kses_post($custom_likes->post_likes(''));
45 45
 					}
46 46
 				}
47 47
 				?>
Please login to merge, or discard this patch.
page-templates/template-full-width.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -20,14 +20,14 @@  discard block
 block discarded – undo
20 20
 
21 21
 		<?php lsx_content_top(); ?>
22 22
 
23
-		<?php if ( have_posts() ) : ?>
23
+		<?php if (have_posts()) : ?>
24 24
 
25 25
 			<?php
26
-			while ( have_posts() ) :
26
+			while (have_posts()) :
27 27
 				the_post();
28 28
 				?>
29 29
 
30
-				<?php get_template_part( 'partials/content', 'page' ); ?>
30
+				<?php get_template_part('partials/content', 'page'); ?>
31 31
 
32 32
 			<?php endwhile; ?>
33 33
 
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
 		<?php lsx_content_bottom(); ?>
37 37
 
38 38
 		<?php
39
-		if ( comments_open() ) {
39
+		if (comments_open()) {
40 40
 			comments_template();
41 41
 		}
42 42
 		?>
Please login to merge, or discard this patch.
page-templates/template-no-sidebar.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -20,14 +20,14 @@  discard block
 block discarded – undo
20 20
 
21 21
 		<?php lsx_content_top(); ?>
22 22
 
23
-		<?php if ( have_posts() ) : ?>
23
+		<?php if (have_posts()) : ?>
24 24
 
25 25
 			<?php
26
-			while ( have_posts() ) :
26
+			while (have_posts()) :
27 27
 				the_post();
28 28
 				?>
29 29
 
30
-				<?php get_template_part( 'partials/content', 'page' ); ?>
30
+				<?php get_template_part('partials/content', 'page'); ?>
31 31
 
32 32
 			<?php endwhile; ?>
33 33
 
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
 		<?php lsx_content_bottom(); ?>
37 37
 
38 38
 		<?php
39
-		if ( comments_open() ) {
39
+		if (comments_open()) {
40 40
 			comments_template();
41 41
 		}
42 42
 		?>
Please login to merge, or discard this patch.
includes/gutenberg.php 2 patches
Braces   +6 added lines, -4 removed lines patch added patch discarded remove patch
@@ -26,8 +26,9 @@  discard block
 block discarded – undo
26 26
  */
27 27
 function add_gutenberg_compatible_body_class( $classes ) {
28 28
 	// if ( ! is_home() && ! is_front_page() ).
29
-	if ( is_page() || is_page_template() || is_single() )
30
-		$classes[] = 'gutenberg-compatible-template';
29
+	if ( is_page() || is_page_template() || is_single() ) {
30
+			$classes[] = 'gutenberg-compatible-template';
31
+	}
31 32
 
32 33
 	// Add a class if the page is using the Content and Media block.
33 34
 	$post = get_post();
@@ -48,8 +49,9 @@  discard block
 block discarded – undo
48 49
 
49 50
 // Add custom class for templates that are using the Gutenberg editor.
50 51
 add_action('body_class', function( $classes ) {
51
-	if ( function_exists( 'has_blocks' ) && has_blocks( get_the_ID() ) && ( ( is_singular( 'post' ) || is_page() ) ) )
52
-		$classes[] = 'using-gutenberg';
52
+	if ( function_exists( 'has_blocks' ) && has_blocks( get_the_ID() ) && ( ( is_singular( 'post' ) || is_page() ) ) ) {
53
+			$classes[] = 'using-gutenberg';
54
+	}
53 55
 	return $classes;
54 56
 });
55 57
 
Please login to merge, or discard this patch.
Spacing   +15 added lines, -15 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@  discard block
 block discarded – undo
6 6
  * @subpackage Gutenberg
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) {
9
+if ( ! defined('ABSPATH')) {
10 10
 	exit;
11 11
 }
12 12
 
@@ -14,9 +14,9 @@  discard block
 block discarded – undo
14 14
  * Enqueue Admin styles on admin area
15 15
  */
16 16
 function load_gutenberg_admin_style() {
17
-	wp_enqueue_style( 'admin_css', get_template_directory_uri() . '/assets/css/admin/gutenberg-admin.css', false, '1.0.0' );
17
+	wp_enqueue_style('admin_css', get_template_directory_uri() . '/assets/css/admin/gutenberg-admin.css', false, '1.0.0');
18 18
 }
19
-add_action( 'admin_enqueue_scripts', 'load_gutenberg_admin_style' );
19
+add_action('admin_enqueue_scripts', 'load_gutenberg_admin_style');
20 20
 
21 21
 // Gutenberg Compatibility.
22 22
 require get_template_directory() . '/lib/theme-support.php';
@@ -24,31 +24,31 @@  discard block
 block discarded – undo
24 24
 /**
25 25
  * Add custom class for Gutenberg Compatible template
26 26
  */
27
-function add_gutenberg_compatible_body_class( $classes ) {
27
+function add_gutenberg_compatible_body_class($classes) {
28 28
 	// if ( ! is_home() && ! is_front_page() ).
29
-	if ( is_page() || is_page_template() || is_single() )
29
+	if (is_page() || is_page_template() || is_single())
30 30
 		$classes[] = 'gutenberg-compatible-template';
31 31
 
32 32
 	// Add a class if the page is using the Content and Media block.
33 33
 	$post = get_post();
34
-	if ( function_exists( 'has_blocks' ) && isset( $post->post_content ) && has_blocks( $post->post_content ) && ( ! is_search() ) && ( ! is_archive() ) ) {
35
-		$blocks = parse_blocks( $post->post_content );
34
+	if (function_exists('has_blocks') && isset($post->post_content) && has_blocks($post->post_content) && ( ! is_search()) && ( ! is_archive())) {
35
+		$blocks = parse_blocks($post->post_content);
36 36
 
37
-		if ( 'core/media-text' === $blocks[0]['blockName'] ) {
37
+		if ('core/media-text' === $blocks[0]['blockName']) {
38 38
 			$classes[] = 'has-block-media-text';
39 39
 		}
40
-		if ( 'core/cover' === $blocks[0]['blockName'] ) {
40
+		if ('core/cover' === $blocks[0]['blockName']) {
41 41
 			$classes[] = 'has-block-cover';
42 42
 		}
43 43
 	}
44 44
 	return $classes;
45 45
 }
46 46
 
47
-add_filter( 'body_class', __NAMESPACE__ . '\add_gutenberg_compatible_body_class' );
47
+add_filter('body_class', __NAMESPACE__ . '\add_gutenberg_compatible_body_class');
48 48
 
49 49
 // Add custom class for templates that are using the Gutenberg editor.
50
-add_action('body_class', function( $classes ) {
51
-	if ( function_exists( 'has_blocks' ) && has_blocks( get_the_ID() ) && ( ( is_singular( 'post' ) || is_page() ) ) )
50
+add_action('body_class', function($classes) {
51
+	if (function_exists('has_blocks') && has_blocks(get_the_ID()) && ((is_singular('post') || is_page())))
52 52
 		$classes[] = 'using-gutenberg';
53 53
 	return $classes;
54 54
 });
@@ -59,8 +59,8 @@  discard block
 block discarded – undo
59 59
  * @return void
60 60
  */
61 61
 function remove_lsx_page_banner_when_using_blocks() {
62
-	if ( function_exists( 'has_blocks' ) && ( ! class_exists( 'LSX_Banners' ) ) ) {
63
-		add_filter( 'lsx_page_banner_disable', '__return_true' );
62
+	if (function_exists('has_blocks') && ( ! class_exists('LSX_Banners'))) {
63
+		add_filter('lsx_page_banner_disable', '__return_true');
64 64
 	}
65 65
 }
66
-add_filter( 'init', 'remove_lsx_page_banner_when_using_blocks' );
66
+add_filter('init', 'remove_lsx_page_banner_when_using_blocks');
Please login to merge, or discard this patch.
includes/sensei/class-lsx-sensei-course.php 1 patch
Spacing   +32 added lines, -32 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@  discard block
 block discarded – undo
6 6
  * @subpackage sensei
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) {
9
+if ( ! defined('ABSPATH')) {
10 10
 	exit; // Exit if accessed directly.
11 11
 }
12 12
 
@@ -26,7 +26,7 @@  discard block
 block discarded – undo
26 26
 	 * Constructor.
27 27
 	 */
28 28
 	public function __construct() {
29
-		add_action( 'init', array( $this, 'init' ) );
29
+		add_action('init', array($this, 'init'));
30 30
 	} // End __construct()
31 31
 
32 32
 	/**
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
 	 * @return self
36 36
 	 */
37 37
 	public static function instance() {
38
-		if ( ! self::$instance ) {
38
+		if ( ! self::$instance) {
39 39
 			self::$instance = new self();
40 40
 		}
41 41
 		return self::$instance;
@@ -49,32 +49,32 @@  discard block
 block discarded – undo
49 49
 		global $woothemes_sensei;
50 50
 
51 51
 		// Switching the course filters and the headers around.
52
-		remove_action( 'sensei_archive_before_course_loop', array( 'Sensei_Course', 'archive_header' ), 10, 0 );
53
-		remove_action( 'sensei_archive_before_course_loop', array( 'Sensei_Course', 'course_archive_sorting' ) );
54
-		remove_action( 'sensei_archive_before_course_loop', array( 'Sensei_Course', 'course_archive_filters' ) );
55
-		add_action( 'sensei_archive_before_course_loop', array( 'Sensei_Course', 'archive_header' ), 11, 0 );
56
-		add_action( 'sensei_archive_before_course_loop', array( 'Sensei_Course', 'course_archive_sorting' ), 12 );
57
-		add_action( 'sensei_archive_before_course_loop', array( 'Sensei_Course', 'course_archive_filters' ), 12 );
52
+		remove_action('sensei_archive_before_course_loop', array('Sensei_Course', 'archive_header'), 10, 0);
53
+		remove_action('sensei_archive_before_course_loop', array('Sensei_Course', 'course_archive_sorting'));
54
+		remove_action('sensei_archive_before_course_loop', array('Sensei_Course', 'course_archive_filters'));
55
+		add_action('sensei_archive_before_course_loop', array('Sensei_Course', 'archive_header'), 11, 0);
56
+		add_action('sensei_archive_before_course_loop', array('Sensei_Course', 'course_archive_sorting'), 12);
57
+		add_action('sensei_archive_before_course_loop', array('Sensei_Course', 'course_archive_filters'), 12);
58 58
 
59 59
 		// First add the thumbnail.
60
-		add_action( 'sensei_course_content_inside_before', array( $this, 'get_course_thumbnail' ), 1 );
60
+		add_action('sensei_course_content_inside_before', array($this, 'get_course_thumbnail'), 1);
61 61
 
62 62
 		// This is for our wrapper, we run it on 2, after the thumbnail we added.
63
-		add_action( 'sensei_course_content_inside_before', array( $this, 'course_body_div_open' ), 1 );
64
-		add_action( 'sensei_course_content_inside_after', array( $this, 'course_body_div_close' ), 50 );
63
+		add_action('sensei_course_content_inside_before', array($this, 'course_body_div_open'), 1);
64
+		add_action('sensei_course_content_inside_after', array($this, 'course_body_div_close'), 50);
65 65
 
66 66
 		// This is for our wrapper, we run it on 2, after the thumbnail we added.
67
-		add_action( 'sensei_course_content_inside_before', array( $this, 'course_body_div_results_open' ), 20 );
68
-		add_action( 'sensei_course_content_inside_after', array( $this, 'course_body_div_results_close' ), 49 );
67
+		add_action('sensei_course_content_inside_before', array($this, 'course_body_div_results_open'), 20);
68
+		add_action('sensei_course_content_inside_after', array($this, 'course_body_div_results_close'), 49);
69 69
 
70
-		add_action( 'sensei_single_course_content_inside_before', array( $this, 'display_course_amount' ), 20 );
70
+		add_action('sensei_single_course_content_inside_before', array($this, 'display_course_amount'), 20);
71 71
 
72 72
 		// removes the course image above the content.
73
-		remove_action( 'sensei_course_content_inside_before', array( $woothemes_sensei->course, 'course_image' ), 30, 1 );
73
+		remove_action('sensei_course_content_inside_before', array($woothemes_sensei->course, 'course_image'), 30, 1);
74 74
 		// add the course image to the left of the content.
75
-		add_action( 'lsx_sensei_course_content_inside_before', array( $woothemes_sensei->course, 'course_image' ), 30, 1 );
75
+		add_action('lsx_sensei_course_content_inside_before', array($woothemes_sensei->course, 'course_image'), 30, 1);
76 76
 
77
-		add_filter( 'attach_shortcode_hooks', 'lsx_attach_shortcode_hooks', 10, 1 );
77
+		add_filter('attach_shortcode_hooks', 'lsx_attach_shortcode_hooks', 10, 1);
78 78
 
79 79
 	}
80 80
 
@@ -86,7 +86,7 @@  discard block
 block discarded – undo
86 86
 	public function get_course_thumbnail() {
87 87
 		?>
88 88
 		<div class="course-thumbnail">
89
-			<?php do_action( 'lsx_sensei_course_content_inside_before', get_the_ID() ); ?>
89
+			<?php do_action('lsx_sensei_course_content_inside_before', get_the_ID()); ?>
90 90
 		</div>
91 91
 		<?php
92 92
 	}
@@ -98,13 +98,13 @@  discard block
 block discarded – undo
98 98
 	 */
99 99
 	public function course_body_div_open() {
100 100
 		global $post, $current_user;
101
-		$is_user_taking_course    = Sensei_Utils::has_started_course( $post->ID, $current_user->ID );
101
+		$is_user_taking_course    = Sensei_Utils::has_started_course($post->ID, $current_user->ID);
102 102
 		$user_taking_course_class = '';
103
-		if ( ! empty( $is_user_taking_course ) ) {
103
+		if ( ! empty($is_user_taking_course)) {
104 104
 			$user_taking_course_class = 'currently-in-course';
105 105
 		}
106 106
 		?>
107
-		<div class="course-body <?php echo esc_html( $user_taking_course_class ); ?>">
107
+		<div class="course-body <?php echo esc_html($user_taking_course_class); ?>">
108 108
 		<?php
109 109
 	}
110 110
 
@@ -148,18 +148,18 @@  discard block
 block discarded – undo
148 148
 	 */
149 149
 	public function display_course_amount() {
150 150
 		global $post, $current_user;
151
-		$is_user_taking_course   = Sensei_Course::is_user_enrolled( $post->ID, $current_user->ID );
152
-		$is_user_starting_course = Sensei_Utils::has_started_course( $post->ID, $current_user->ID );
153
-		$wc_post_id              = absint( get_post_meta( $post->ID, '_course_woocommerce_product', true ) );
151
+		$is_user_taking_course   = Sensei_Course::is_user_enrolled($post->ID, $current_user->ID);
152
+		$is_user_starting_course = Sensei_Utils::has_started_course($post->ID, $current_user->ID);
153
+		$wc_post_id              = absint(get_post_meta($post->ID, '_course_woocommerce_product', true));
154 154
 		$course_purchasable      = '';
155
-		if ( class_exists( 'Sensei_WC' ) ) {
156
-			$course_purchasable = Sensei_WC::is_course_purchasable( $post->ID );
155
+		if (class_exists('Sensei_WC')) {
156
+			$course_purchasable = Sensei_WC::is_course_purchasable($post->ID);
157 157
 			$currency           = get_woocommerce_currency_symbol();
158
-			$product            = new WC_Product( $wc_post_id );
159
-			if ( ( ! empty( $product->get_price() ) ) && ( ( ! $is_user_taking_course ) || ( ! $is_user_starting_course ) ) ) {
160
-				echo '<span class="course-product-price price"><span>' . esc_html( $currency ) . ' </span>' . sprintf( '%0.2f', esc_html( $product->get_price() ) ) . '</span>';
161
-			} elseif ( ( '' === $product->get_price() || 0 == $product->get_price() ) && $course_purchasable && ( ( ! $is_user_taking_course ) || ( ! $is_user_starting_course ) ) ) {
162
-				echo '<span class="course-product-price price">' . wp_kses_post( 'Free!', 'lsx' ) . '</span>';
158
+			$product            = new WC_Product($wc_post_id);
159
+			if (( ! empty($product->get_price())) && (( ! $is_user_taking_course) || ( ! $is_user_starting_course))) {
160
+				echo '<span class="course-product-price price"><span>' . esc_html($currency) . ' </span>' . sprintf('%0.2f', esc_html($product->get_price())) . '</span>';
161
+			} elseif (('' === $product->get_price() || 0 == $product->get_price()) && $course_purchasable && (( ! $is_user_taking_course) || ( ! $is_user_starting_course))) {
162
+				echo '<span class="course-product-price price">' . wp_kses_post('Free!', 'lsx') . '</span>';
163 163
 			}
164 164
 		}
165 165
 	}
Please login to merge, or discard this patch.
lib/theme-support.php 1 patch
Spacing   +37 added lines, -37 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@  discard block
 block discarded – undo
13 13
 	);
14 14
 
15 15
 }
16
-add_action( 'admin_init', 'editor_styles' );
16
+add_action('admin_init', 'editor_styles');
17 17
 
18 18
 /**
19 19
  * Add theme support functions.
@@ -21,7 +21,7 @@  discard block
 block discarded – undo
21 21
  * @package lsx
22 22
  */
23 23
 
24
-if ( ! function_exists( 'theme_support' ) ) :
24
+if ( ! function_exists('theme_support')) :
25 25
 	/**
26 26
 	 * Add theme support functions.
27 27
 	 *
@@ -29,44 +29,44 @@  discard block
 block discarded – undo
29 29
 	 */
30 30
 	function theme_support() {
31 31
 		// Add support for editor styles.
32
-		add_theme_support( 'editor-styles' );
32
+		add_theme_support('editor-styles');
33 33
 		// Add support for full and wide align images.
34
-		add_theme_support( 'align-wide' );
34
+		add_theme_support('align-wide');
35 35
 		// Add support for styling blocks.
36
-		add_theme_support( 'wp-block-styles' );
36
+		add_theme_support('wp-block-styles');
37 37
 		// Add support for responsive embedded content.
38
-		add_theme_support( 'responsive-embeds' );
38
+		add_theme_support('responsive-embeds');
39 39
 		// Add custom editor font sizes.
40 40
 		add_theme_support(
41 41
 			'editor-font-sizes',
42 42
 			array(
43 43
 				array(
44
-					'name'      => esc_html_x( 'Small', 'font size option label', 'lsx' ),
45
-					'shortName' => esc_html_x( 'S', 'abbreviation of the font size option label', 'lsx' ),
44
+					'name'      => esc_html_x('Small', 'font size option label', 'lsx'),
45
+					'shortName' => esc_html_x('S', 'abbreviation of the font size option label', 'lsx'),
46 46
 					'size'      => 13,
47 47
 					'slug'      => 'small',
48 48
 				),
49 49
 				array(
50
-					'name'      => esc_html_x( 'Normal', 'font size option label', 'lsx' ),
51
-					'shortName' => esc_html_x( 'N', 'abbreviation of the font size option label', 'lsx' ),
50
+					'name'      => esc_html_x('Normal', 'font size option label', 'lsx'),
51
+					'shortName' => esc_html_x('N', 'abbreviation of the font size option label', 'lsx'),
52 52
 					'size'      => 15,
53 53
 					'slug'      => 'normal',
54 54
 				),
55 55
 				array(
56
-					'name'      => esc_html_x( 'Medium', 'font size option label', 'lsx' ),
57
-					'shortName' => esc_html_x( 'M', 'abbreviation of the font size option label', 'lsx' ),
56
+					'name'      => esc_html_x('Medium', 'font size option label', 'lsx'),
57
+					'shortName' => esc_html_x('M', 'abbreviation of the font size option label', 'lsx'),
58 58
 					'size'      => 22,
59 59
 					'slug'      => 'medium',
60 60
 				),
61 61
 				array(
62
-					'name'      => esc_html_x( 'Large', 'font size option label', 'lsx' ),
63
-					'shortName' => esc_html_x( 'L', 'abbreviation of the font size option label', 'lsx' ),
62
+					'name'      => esc_html_x('Large', 'font size option label', 'lsx'),
63
+					'shortName' => esc_html_x('L', 'abbreviation of the font size option label', 'lsx'),
64 64
 					'size'      => 30,
65 65
 					'slug'      => 'large',
66 66
 				),
67 67
 				array(
68
-					'name'      => esc_html_x( 'Huge', 'font size option label', 'lsx' ),
69
-					'shortName' => esc_html_x( 'XL', 'abbreviation of the font size option label', 'lsx' ),
68
+					'name'      => esc_html_x('Huge', 'font size option label', 'lsx'),
69
+					'shortName' => esc_html_x('XL', 'abbreviation of the font size option label', 'lsx'),
70 70
 					'size'      => 40,
71 71
 					'slug'      => 'huge',
72 72
 				),
@@ -74,48 +74,48 @@  discard block
 block discarded – undo
74 74
 		);
75 75
 
76 76
 		// Add support for custom color scheme.
77
-		add_theme_support( 'editor-color-palette', array(
77
+		add_theme_support('editor-color-palette', array(
78 78
 			array(
79
-				'name'  => __( 'Strong Blue', 'lsx' ),
79
+				'name'  => __('Strong Blue', 'lsx'),
80 80
 				'slug'  => 'strong-blue',
81 81
 				'color' => '#27639e',
82 82
 			),
83 83
 			array(
84
-				'name'  => __( 'Lighter Blue', 'lsx' ),
84
+				'name'  => __('Lighter Blue', 'lsx'),
85 85
 				'slug'  => 'lighter-blue',
86 86
 				'color' => '#428bca',
87 87
 			),
88 88
 			array(
89
-				'name'  => __( 'Yellow', 'lsx' ),
89
+				'name'  => __('Yellow', 'lsx'),
90 90
 				'slug'  => 'light-yellow',
91 91
 				'color' => '#f7ae00',
92 92
 			),
93 93
 			array(
94
-				'name'  => __( 'Dark Yellow', 'lsx' ),
94
+				'name'  => __('Dark Yellow', 'lsx'),
95 95
 				'slug'  => 'dark-yellow',
96 96
 				'color' => '#ab7800',
97 97
 			),
98 98
 			array(
99
-				'name'  => __( 'Green', 'lsx' ),
99
+				'name'  => __('Green', 'lsx'),
100 100
 				'slug'  => 'light-green',
101 101
 				'color' => '#6BA913',
102 102
 			),
103 103
 			array(
104
-				'name'  => __( 'Dark Green', 'lsx' ),
104
+				'name'  => __('Dark Green', 'lsx'),
105 105
 				'slug'  => 'dark-green',
106 106
 				'color' => '#3F640B',
107 107
 			),
108 108
 			array(
109
-				'name'  => __( 'White', 'lsx' ),
109
+				'name'  => __('White', 'lsx'),
110 110
 				'slug'  => 'white',
111 111
 				'color' => '#ffffff',
112 112
 			),
113 113
 			array(
114
-				'name'  => __( 'Black', 'lsx' ),
114
+				'name'  => __('Black', 'lsx'),
115 115
 				'slug'  => 'black',
116 116
 				'color' => '#000000',
117 117
 			),
118
-		) );
118
+		));
119 119
 
120 120
 		$primary_color    = 'rgba(39,99,158,1)';
121 121
 		$secondary_color  = 'rgba(247,174,0,1)';
@@ -126,30 +126,30 @@  discard block
 block discarded – undo
126 126
 			'editor-gradient-presets',
127 127
 			array(
128 128
 				array(
129
-					'name'     => __( 'Primary to Secondary', 'lsx' ),
130
-					'gradient' => 'linear-gradient(135deg, ' . esc_attr( $primary_color ) . ' 0%, ' . esc_attr( $secondary_color ) . ' 100%)',
129
+					'name'     => __('Primary to Secondary', 'lsx'),
130
+					'gradient' => 'linear-gradient(135deg, ' . esc_attr($primary_color) . ' 0%, ' . esc_attr($secondary_color) . ' 100%)',
131 131
 					'slug'     => 'primary-to-secondary',
132 132
 				),
133 133
 				array(
134
-					'name'     => __( 'Primary to Tertiary', 'lsx' ),
135
-					'gradient' => 'linear-gradient(135deg, ' . esc_attr( $primary_color ) . ' 0%, ' . esc_attr( $tertiary_color ) . ' 100%)',
134
+					'name'     => __('Primary to Tertiary', 'lsx'),
135
+					'gradient' => 'linear-gradient(135deg, ' . esc_attr($primary_color) . ' 0%, ' . esc_attr($tertiary_color) . ' 100%)',
136 136
 					'slug'     => 'primary-to-tertiary',
137 137
 				),
138 138
 				array(
139
-					'name'     => __( 'Primary to Background', 'lsx' ),
140
-					'gradient' => 'linear-gradient(135deg, ' . esc_attr( $primary_color ) . ' 0%, ' . esc_attr( $background_color ) . ' 100%)',
139
+					'name'     => __('Primary to Background', 'lsx'),
140
+					'gradient' => 'linear-gradient(135deg, ' . esc_attr($primary_color) . ' 0%, ' . esc_attr($background_color) . ' 100%)',
141 141
 					'slug'     => 'primary-to-background',
142 142
 				),
143 143
 				array(
144
-					'name'     => __( 'Secondary to Tertiary', 'lsx' ),
145
-					'gradient' => 'linear-gradient(135deg, ' . esc_attr( $secondary_color ) . ' 0%, ' . esc_attr( $tertiary_color ) . ' 100%)',
144
+					'name'     => __('Secondary to Tertiary', 'lsx'),
145
+					'gradient' => 'linear-gradient(135deg, ' . esc_attr($secondary_color) . ' 0%, ' . esc_attr($tertiary_color) . ' 100%)',
146 146
 					'slug'     => 'secondary-to-tertiary',
147 147
 				),
148 148
 			)
149 149
 		);
150 150
 	}
151 151
 endif;
152
-add_action( 'after_setup_theme', 'theme_support' );
152
+add_action('after_setup_theme', 'theme_support');
153 153
 
154 154
 /**
155 155
  * WPForms submit button, match Gutenberg button block
@@ -157,8 +157,8 @@  discard block
 block discarded – undo
157 157
  * @param [type] $form_data
158 158
  * @return void
159 159
  */
160
-function lsx_wpforms_match_button_block( $form_data ) {
160
+function lsx_wpforms_match_button_block($form_data) {
161 161
 	$form_data['settings']['submit_class'] .= ' btn';
162 162
 	return $form_data;
163 163
 }
164
-add_filter( 'wpforms_frontend_form_data', 'lsx_wpforms_match_button_block' );
164
+add_filter('wpforms_frontend_form_data', 'lsx_wpforms_match_button_block');
Please login to merge, or discard this patch.
includes/yoast/class-lsx-yoast.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -6,11 +6,11 @@  discard block
 block discarded – undo
6 6
  * @subpackage yoast
7 7
  */
8 8
 
9
-if ( ! defined( 'ABSPATH' ) ) {
9
+if ( ! defined('ABSPATH')) {
10 10
 	exit;
11 11
 }
12 12
 
13
-if ( ! class_exists( 'LSX_Yoast' ) ) :
13
+if ( ! class_exists('LSX_Yoast')) :
14 14
 
15 15
 	/**
16 16
 	 * The LSX Yoast integration class
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
 		 */
33 33
 		public function __construct() {
34 34
 
35
-			add_action( 'wp_enqueue_scripts', array( $this, 'lsx_yoast_scripts_add_styles' ) );
35
+			add_action('wp_enqueue_scripts', array($this, 'lsx_yoast_scripts_add_styles'));
36 36
 		}
37 37
 
38 38
 		/**
@@ -43,7 +43,7 @@  discard block
 block discarded – undo
43 43
 		 */
44 44
 		public static function get_instance() {
45 45
 			// If the single instance hasn't been set, set it now.
46
-			if ( null === self::$instance ) {
46
+			if (null === self::$instance) {
47 47
 				self::$instance = new self();
48 48
 			}
49 49
 			return self::$instance;
@@ -56,8 +56,8 @@  discard block
 block discarded – undo
56 56
 		 * @subpackage yoast
57 57
 		 */
58 58
 		public function lsx_yoast_scripts_add_styles() {
59
-			wp_enqueue_script( 'lsx_yoast_js', get_template_directory_uri() . '/assets/js/yoast/yoast.js', array( 'jquery' ), LSX_VERSION, true );
60
-			wp_enqueue_style( 'lsx_yoast_css', get_template_directory_uri() . '/assets/css/yoast/yoast.css', array( 'lsx_main' ), LSX_VERSION );
59
+			wp_enqueue_script('lsx_yoast_js', get_template_directory_uri() . '/assets/js/yoast/yoast.js', array('jquery'), LSX_VERSION, true);
60
+			wp_enqueue_style('lsx_yoast_css', get_template_directory_uri() . '/assets/css/yoast/yoast.css', array('lsx_main'), LSX_VERSION);
61 61
 		}
62 62
 	}
63 63
 
Please login to merge, or discard this patch.
header.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -11,14 +11,14 @@
 block discarded – undo
11 11
 <html <?php language_attributes(); ?>>
12 12
 	<head>
13 13
 		<?php lsx_head_top(); ?>
14
-		<meta charset="<?php bloginfo( 'charset' ); ?>">
14
+		<meta charset="<?php bloginfo('charset'); ?>">
15 15
 		<link rel="profile" href="http://gmpg.org/xfn/11">
16
-		<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
16
+		<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>">
17 17
 		<?php lsx_head_bottom(); ?>
18 18
 		<?php wp_head(); ?>
19 19
 	</head>
20 20
 
21
-	<body <?php body_class( 'lsx' ); ?>>
21
+	<body <?php body_class('lsx'); ?>>
22 22
 		<?php wp_body_open(); ?>
23 23
 		<?php lsx_body_top(); ?>
24 24
 
Please login to merge, or discard this patch.