From 9baf0b29fb87470a8d8de960e51fb6744a003b05 Mon Sep 17 00:00:00 2001 From: Oral UNAL Date: Fri, 4 Aug 2017 23:31:07 +0300 Subject: [PATCH 1/3] Update package.json package name corrected --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 14e69cb..eee4dc1 100644 --- a/package.json +++ b/package.json @@ -49,6 +49,6 @@ "merge2": "^1.1.0", "run-sequence": "^2.0.0", "gulp-sequence": "^0.4.6", - "undescores-for-npm": "^1.0.0" + "underscores-for-npm": "^1.0.0" } } From c5a142b76216ef50de7cb903a932b7b792d1b01f Mon Sep 17 00:00:00 2001 From: Oral UNAL Date: Sat, 5 Aug 2017 00:39:22 +0300 Subject: [PATCH 2/3] Update theme-settings.php If someone tries to override in child temp --- inc/theme-settings.php | 39 +++++++++++++++++++++------------------ 1 file changed, 21 insertions(+), 18 deletions(-) diff --git a/inc/theme-settings.php b/inc/theme-settings.php index 47cacfa..16cf7db 100644 --- a/inc/theme-settings.php +++ b/inc/theme-settings.php @@ -5,25 +5,28 @@ * @package understrap * */ -function setup_theme_default_settings() { - // check if settings are set, if not set defaults. - // Caution: DO NOT check existence using === always check with == . - // Latest blog posts style. - $understrap_posts_index_style = get_theme_mod( 'understrap_posts_index_style' ); - if ( '' == $understrap_posts_index_style ) { - set_theme_mod( 'understrap_posts_index_style', 'default' ); - } +if ( ! function_exists( 'setup_theme_default_settings' ) ) : + function setup_theme_default_settings() { - // Sidebar position. - $understrap_sidebar_position = get_theme_mod( 'understrap_sidebar_position' ); - if ( '' == $understrap_sidebar_position ) { - set_theme_mod( 'understrap_sidebar_position', 'right' ); - } + // check if settings are set, if not set defaults. + // Caution: DO NOT check existence using === always check with == . + // Latest blog posts style. + $understrap_posts_index_style = get_theme_mod( 'understrap_posts_index_style' ); + if ( '' == $understrap_posts_index_style ) { + set_theme_mod( 'understrap_posts_index_style', 'default' ); + } - // Container width. - $understrap_container_type = get_theme_mod( 'understrap_container_type' ); - if ( '' == $understrap_container_type ) { - set_theme_mod( 'understrap_container_type', 'container' ); + // Sidebar position. + $understrap_sidebar_position = get_theme_mod( 'understrap_sidebar_position' ); + if ( '' == $understrap_sidebar_position ) { + set_theme_mod( 'understrap_sidebar_position', 'right' ); + } + + // Container width. + $understrap_container_type = get_theme_mod( 'understrap_container_type' ); + if ( '' == $understrap_container_type ) { + set_theme_mod( 'understrap_container_type', 'container' ); + } } -} +endif; From 6a2d794144e8ff39c1a8e3040d87fdf92399f8d4 Mon Sep 17 00:00:00 2001 From: Oral UNAL Date: Sat, 5 Aug 2017 00:40:36 +0300 Subject: [PATCH 3/3] Update security.php remove_action can take accept only 3 params --- inc/security.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/inc/security.php b/inc/security.php index 2cbcd5a..8130798 100644 --- a/inc/security.php +++ b/inc/security.php @@ -25,8 +25,8 @@ remove_action( 'wp_head', 'wlwmanifest_link' ); remove_action( 'wp_head', 'index_rel_link' ); remove_action( 'wp_head', 'feed_links', 2 ); remove_action( 'wp_head', 'feed_links_extra', 3 ); -remove_action( 'wp_head', 'adjacent_posts_rel_link_wp_head', 10, 0 ); -remove_action( 'wp_head', 'wp_shortlink_wp_head', 10, 0 ); +remove_action( 'wp_head', 'adjacent_posts_rel_link_wp_head', 10); +remove_action( 'wp_head', 'wp_shortlink_wp_head', 10); /** * Show less info to users on failed login for security.