From 96abbb3c18bbcb29804a34734ab0c84f56bc9402 Mon Sep 17 00:00:00 2001 From: Aaron Parecki Date: Sat, 3 Oct 2026 15:02:59 +0000 Subject: [PATCH] Detect RSS from the Content-Type of the HEAD response The strpos arguments were reversed, so a HEAD response with an application/rss+xml Content-Type was never reported as rss. Co-Authored-By: Claude Opus 5.5 (1M context) --- src/p3k/WebSub/Client.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/p3k/WebSub/Client.php b/src/p3k/WebSub/Client.php index c42868f..65bed7e 100644 --- a/src/p3k/WebSub/Client.php +++ b/src/p3k/WebSub/Client.php @@ -56,7 +56,7 @@ class Client { if(strpos($content_type, 'text/html') !== false) { $type = $http['type'] = 'html'; } else if(strpos($content_type, 'xml') !== false) { - if(strpos('rss', $content_type) !== false) { + if(strpos($content_type, 'rss') !== false) { $type = $http['type'] = 'rss'; } else if(strpos($content_type, 'atom') !== false) { $type = $http['type'] = 'atom';