Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion src/wp-admin/includes/export.php
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,6 @@ function wxr_filter_postmeta( $return_me, $meta_key ) {
<rss version="2.0"
xmlns:excerpt="http://wordpress.org/export/<?php echo WXR_VERSION; ?>/excerpt/"
xmlns:content="http://purl.org/rss/1.0/modules/content/"
xmlns:wfw="http://wellformedweb.org/CommentAPI/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:wp="http://wordpress.org/export/<?php echo WXR_VERSION; ?>/"
>
Expand Down
2 changes: 0 additions & 2 deletions src/wp-includes/feed-rss2.php
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
<?php
/**
* RSS2 Feed Template for displaying RSS2 Posts feed.
Expand All @@ -22,7 +22,6 @@
?>
<rss version="2.0"
xmlns:content="http://purl.org/rss/1.0/modules/content/"
xmlns:wfw="http://wellformedweb.org/CommentAPI/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
Expand Down Expand Up @@ -110,7 +109,6 @@
<?php endif; ?>

<?php if ( get_comments_number() || comments_open() ) : ?>
<wfw:commentRss><?php echo esc_url( get_post_comments_feed_link( null, 'rss2' ) ); ?></wfw:commentRss>
<slash:comments><?php echo get_comments_number(); ?></slash:comments>
<?php endif; ?>

Expand Down
9 changes: 0 additions & 9 deletions tests/phpunit/tests/feed/rss2.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,6 @@ public function test_rss_element() {

$this->assertSame( '2.0', $rss[0]['attributes']['version'] );
$this->assertSame( 'http://purl.org/rss/1.0/modules/content/', $rss[0]['attributes']['xmlns:content'] );
$this->assertSame( 'http://wellformedweb.org/CommentAPI/', $rss[0]['attributes']['xmlns:wfw'] );
$this->assertSame( 'http://purl.org/dc/elements/1.1/', $rss[0]['attributes']['xmlns:dc'] );

// RSS should have exactly one child element (channel).
Expand Down Expand Up @@ -269,10 +268,6 @@ public function test_item_elements() {
$content = xml_find( $items[ $key ]['child'], 'content:encoded' );
$this->assertSame( trim( apply_filters( 'the_content', $post->post_content ) ), trim( $content[0]['content'] ) );
}

// Comment RSS.
$comment_rss = xml_find( $items[ $key ]['child'], 'wfw:commentRss' );
$this->assertSame( html_entity_decode( get_post_comments_feed_link( $post->ID ) ), $comment_rss[0]['content'] );
}
}

Expand Down Expand Up @@ -301,10 +296,6 @@ public function test_items_comments_closed() {
// Comment link.
$comments_link = xml_find( $items[ $key ]['child'], 'comments' );
$this->assertEmpty( $comments_link );

// Comment RSS.
$comment_rss = xml_find( $items[ $key ]['child'], 'wfw:commentRss' );
$this->assertEmpty( $comment_rss );
}

remove_filter( 'comments_open', '__return_false' );
Expand Down
Loading