Skip to content

Commit

Permalink
#2997 #2873 Some more improvements related to performance
Browse files Browse the repository at this point in the history
  • Loading branch information
MARQAS committed Apr 5, 2019
1 parent d5ec666 commit f03691d
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 22 deletions.
2 changes: 1 addition & 1 deletion components/breadcrumb/breadcrumb.php
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@
$term_id = get_query_var('tag_id');
$taxonomy = 'post_tag';
$args = 'include=' . $term_id;
$terms = get_terms( $taxonomy, $args );
$terms = get_the_terms( $post->ID,'post_tag' );
$get_term_id = $terms[0]->term_id;
$get_term_slug = $terms[0]->slug;
$get_term_name = $terms[0]->name;
Expand Down
18 changes: 0 additions & 18 deletions includes/options/admin-config.php
Original file line number Diff line number Diff line change
Expand Up @@ -2227,15 +2227,6 @@ function ampforwp_cpt_hide_amp_bulk($fields){
'required'=>array('amp-on-off-for-all-posts','=','1'),
),
array(
'id' =>'hide-amp-categories',
'type' => 'checkbox_hierarchy',
'title' => __('Select Categories to Hide AMP'),
'tooltip-subtitle' => __( 'Hide AMP from all the posts of a selected category.', 'accelerated-mobile-pages' ),
'default' => 0,
'data' => 'category_list_hierarchy',
'class' => 'hide'
),
array(
'id' =>'hide-amp-categories2',
'type' => 'select',
'title' => __('Select Categories to Hide AMP'),
Expand All @@ -2245,15 +2236,6 @@ function ampforwp_cpt_hide_amp_bulk($fields){
'data-action' => 'categories',
'data' => 'categories',
),
array(
'id' =>'hide-amp-tags-bulk-option',
'type' => 'checkbox',
'title' => __('Select Tags to Hide AMP'),
'tooltip-subtitle' => __( 'Hide AMP from all the posts of a selected tags.', 'accelerated-mobile-pages' ),
'default' => 0,
'data' => 'tags',
'class' => 'hide'
),
array(
'id' =>'hide-amp-tags-bulk-option2',
'type' => 'select',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@
$term_id = get_query_var('tag_id');
$taxonomy = 'post_tag';
$args = 'include=' . $term_id;
$terms = get_terms( $taxonomy, $args );
$terms = get_the_terms( $post->ID, 'post_tag' );
$get_term_id = $terms[0]->term_id;
$get_term_slug = $terms[0]->slug;
$get_term_name = $terms[0]->name;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@
$term_id = get_query_var('tag_id');
$taxonomy = 'post_tag';
$args = 'include=' . $term_id;
$terms = get_terms( $taxonomy, $args );
$terms = get_the_terms( $post->ID, 'post_tag' );
$get_term_id = $terms[0]->term_id;
$get_term_slug = $terms[0]->slug;
$get_term_name = $terms[0]->name;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@
$term_id = get_query_var('tag_id');
$taxonomy = 'post_tag';
$args = 'include=' . $term_id;
$terms = get_terms( $taxonomy, $args );
$terms = get_the_terms( $post->ID, 'post_tag' );
$get_term_id = $terms[0]->term_id;
$get_term_slug = $terms[0]->slug;
$get_term_name = $terms[0]->name;
Expand Down

0 comments on commit f03691d

Please sign in to comment.