Drop RSS/Atom feeds, support JSON feeds only

Removes the RSS and Atom feed routes, controller methods, and views
for both the blog and notes feeds, keeping JSON (and JF2) as the only
supported feed formats. Also serves the JSON feeds with the
spec-required application/feed+json MIME type instead of the generic
application/json.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01AXyzNvQZPQgBoSZwW7cLG8
This commit is contained in:
Jonny Barnes 2026-08-22 10:42:16 +01:00
commit 714cd95d79
Signed by: jonny
SSH key fingerprint: SHA256:CTuSlns5U7qlD9jqHvtnVmfYV3Zwl2Z7WnJ4/dqOaL8
8 changed files with 12 additions and 209 deletions

View file

@ -15,42 +15,6 @@ class FeedsTest extends TestCase
{
use RefreshDatabase;
/**
* Test the blog RSS feed.
*/
#[Test]
public function blog_rss_feed_is_present(): void
{
Article::factory()->count(3)->create();
$response = $this->get('/blog/feed.rss');
$response->assertHeader('Content-Type', 'application/rss+xml; charset=utf-8');
$response->assertOk();
}
/**
* Test the notes RSS feed.
*/
#[Test]
public function notes_rss_feed_is_present(): void
{
Note::factory()->count(3)->create();
$response = $this->get('/notes/feed.rss');
$response->assertHeader('Content-Type', 'application/rss+xml; charset=utf-8');
$response->assertOk();
}
/**
* Test the blog RSS feed.
*/
#[Test]
public function blog_atom_feed_is_present(): void
{
Article::factory()->count(3)->create();
$response = $this->get('/blog/feed.atom');
$response->assertHeader('Content-Type', 'application/atom+xml; charset=utf-8');
$response->assertOk();
}
#[Test]
public function blog_jf2_feed_is_present(): void
{
@ -73,18 +37,6 @@ class FeedsTest extends TestCase
]);
}
/**
* Test the notes RSS feed.
*/
#[Test]
public function notes_atom_feed_is_present(): void
{
Note::factory()->count(3)->create();
$response = $this->get('/notes/feed.atom');
$response->assertHeader('Content-Type', 'application/atom+xml; charset=utf-8');
$response->assertOk();
}
/**
* Test the blog JSON feed.
*/
@ -93,7 +45,7 @@ class FeedsTest extends TestCase
{
Article::factory()->count(3)->create();
$response = $this->get('/blog/feed.json');
$response->assertHeader('Content-Type', 'application/json');
$response->assertHeader('Content-Type', 'application/feed+json');
$response->assertOk();
}
@ -105,7 +57,7 @@ class FeedsTest extends TestCase
{
Note::factory()->count(3)->create();
$response = $this->get('/notes/feed.json');
$response->assertHeader('Content-Type', 'application/json');
$response->assertHeader('Content-Type', 'application/feed+json');
$response->assertOk();
}