0 ) {
// If a static page is set as the front page, $pagename will not be set. Retrieve it from the queried object
$current_post = $wp_query->get_queried_object();
$pagename = $current_post->post_name;
}
if( is_archive() ) {
$pagename = get_the_archive_title();
}
$page_heading = ( get_theme_mod( 'page_heading_text', 'Blog' ) ) ? get_theme_mod( 'page_heading_text', 'Blog' ) : $pagename;
$sidebar_active = ( is_active_sidebar( 'sidebar-1' ) && ( get_theme_mod( 'show_page_sidebar', 'yes' ) == 'yes' ) );
$show_sidebar_class = ( $sidebar_active ) ? 'col-lg-9 col-md-12 col-sm-12 col-12' : 'col-lg-12 col-md-12 col-sm-12 col-12';
get_header();
?>