summaryrefslogtreecommitdiff
path: root/app/controllers/rss_controller.rb
diff options
context:
space:
mode:
authorerdgeist <erdgeist@erdgeist.org>2026-06-24 16:17:16 +0200
committererdgeist <erdgeist@erdgeist.org>2026-06-24 16:17:16 +0200
commit75670df5b8a5700c48ac8cb41f8d1732b5738402 (patch)
tree0611ab89cd9fa6aa5c1c7cc44df28de4388c608e /app/controllers/rss_controller.rb
parent61dc69cc5d8089ed9f96bc65dc64de6e075f70cf (diff)
Fix tagged content aggregator, assets path, and add regression tests
- Replace tagged_with calls in Page.aggregate, TagsController, RssController with direct SQL joins (acts-as-taggable-on 3.5 broken on Rails 3.2) - Fix Paperclip :path/:url to use plain :id format matching existing uploads - Add proper regression tests for aggregator, tags, and rss controllers - Fix assert_select assertions to target div.body div.article_partial
Diffstat (limited to 'app/controllers/rss_controller.rb')
-rw-r--r--app/controllers/rss_controller.rb11
1 files changed, 8 insertions, 3 deletions
diff --git a/app/controllers/rss_controller.rb b/app/controllers/rss_controller.rb
index 70a642c..be9cd2c 100644
--- a/app/controllers/rss_controller.rb
+++ b/app/controllers/rss_controller.rb
@@ -7,10 +7,15 @@ class RssController < ApplicationController
7 expires_in 31.minutes, :public => true 7 expires_in 31.minutes, :public => true
8 8
9 I18n.locale = :de 9 I18n.locale = :de
10 10
11 @items = Page.heads.tagged_with("update") 11 @items = Page.heads
12 .joins("JOIN taggings ON taggings.taggable_id = pages.id
13 AND taggings.taggable_type = 'Page'
14 AND taggings.context = 'tags'")
15 .joins("JOIN tags ON tags.id = taggings.tag_id")
16 .where("LOWER(tags.name) = ?", "update")
12 .order("published_at DESC").limit(20) 17 .order("published_at DESC").limit(20)
13 18
14 respond_to do |format| 19 respond_to do |format|
15 format.xml {} 20 format.xml {}
16 format.rdf {} 21 format.rdf {}