Skip to content

Commit

Permalink
Merge pull request #3210 from alphagov/revert-3202-add-content-id-to-…
Browse files Browse the repository at this point in the history
…drug-alerts-feed

Revert "Add document content_id to atom feeds"
  • Loading branch information
KludgeKML authored Nov 14, 2023
2 parents 103adea + 34b4d79 commit 4238cce
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 14 deletions.
1 change: 0 additions & 1 deletion app/presenters/entry_presenter.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
class EntryPresenter
delegate :title,
:path,
:content_id,
to: :entry

WEBSITE_ROOT = Plek.new.website_root.gsub(/https?:\/\//, "")
Expand Down
1 change: 0 additions & 1 deletion app/views/finders/show.atom.builder
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ atom_feed do |feed|
feed.entry(result, id: result.tag(feed), url: absolute_url_for(result.path), updated: result.updated_at) do |entry|
entry.title(result.title)
entry.summary(result.summary, type: "html")
entry.content_id(result.content_id)
end
end
end
12 changes: 0 additions & 12 deletions spec/presenters/entry_presenter_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -35,16 +35,4 @@
expect(EntryPresenter.feed_ended_id(atom_feed_builder, "/path/to/content")).to eq("tag:www.test.gov.uk,2019:/path/to/content/feed-ended")
end
end

# Note - this is a simple delegation and we wouldn't normally test, but
# it's important for email-alert-api's monitoring of medical alerts, so
# worth checking that it hasn't been accidentally removed.
describe "#content_id" do
let(:document) do
FactoryBot.build(:document, content_id: "AAAA-BBBB")
end
it "displays the content_id" do
expect(EntryPresenter.new(document, true).content_id).to eq("AAAA-BBBB")
end
end
end

0 comments on commit 4238cce

Please sign in to comment.