Skip to content

Commit c555e57

Browse files
committed
fix: ad suppression tweak
1 parent ac533c5 commit c555e57

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

includes/class-newspack-sponsors-core.php

+3
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,9 @@ public function __construct() {
5656
* @param int $post_id Post ID.
5757
*/
5858
public static function suppress_ads( $should_display, $post_id ) {
59+
if ( ! is_single() ) {
60+
return $should_display;
61+
}
5962
$sponsors = get_sponsors_for_post( $post_id );
6063
if ( $sponsors && count( $sponsors ) ) {
6164
return false;

0 commit comments

Comments
 (0)