Skip to content

Commit

Permalink
Account for post_supports_amp() in is_paired_available()
Browse files Browse the repository at this point in the history
  • Loading branch information
westonruter committed Jan 17, 2018
1 parent e60cb15 commit 25b2fda
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions includes/class-amp-theme-support.php
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,10 @@ public static function is_paired_available() {
return false;
}

if ( is_singular() && ! post_supports_amp( get_queried_object() ) ) {
return false;
}

$args = array_shift( $support );

if ( isset( $args['available_callback'] ) && is_callable( $args['available_callback'] ) ) {
Expand Down

0 comments on commit 25b2fda

Please sign in to comment.