From 0f4288d91de7b48f7bbed832ca80246b0055cc64 Mon Sep 17 00:00:00 2001 From: erdgeist Date: Sun, 9 Aug 2026 16:03:40 +0200 Subject: Drop nodes.external_url The column moved to page.rb and was now written only by publish_draft! and by the chapter seed, and read by nothing. lib/tasks/pages.rake goes with it. backfill_external_url reads the dropped column. backfill_address is spent and no longer safe to re-run. --- db/migrate/20260809135746_remove_external_url_from_nodes.rb | 5 +++++ db/seeds/chapters.rb | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 db/migrate/20260809135746_remove_external_url_from_nodes.rb (limited to 'db') diff --git a/db/migrate/20260809135746_remove_external_url_from_nodes.rb b/db/migrate/20260809135746_remove_external_url_from_nodes.rb new file mode 100644 index 00000000..0510d053 --- /dev/null +++ b/db/migrate/20260809135746_remove_external_url_from_nodes.rb @@ -0,0 +1,5 @@ +class RemoveExternalUrlFromNodes < ActiveRecord::Migration[8.1] + def change + remove_column :nodes, :external_url, :string + end +end diff --git a/db/seeds/chapters.rb b/db/seeds/chapters.rb index 4d81e3cc..ba14252c 100644 --- a/db/seeds/chapters.rb +++ b/db/seeds/chapters.rb @@ -30,12 +30,13 @@ def seed_chapter(parent_id:, slug:, tag:, title_de:, description_de:, end # Create node - node = parent.children.create!(slug: slug, external_url: external_url) + node = parent.children.create!(slug: slug) node.reload # Set up draft with German translation draft = node.draft draft.template_name = 'chapter_detail' + draft.external_url = external_url I18n.with_locale(:de) do draft.title = title_de draft.abstract = location || "" -- cgit v1.3