diff --git a/db/migrate/20190908031103_drop_related_tags_from_tags.rb b/db/migrate/20190908031103_drop_related_tags_from_tags.rb new file mode 100644 index 000000000..d8d0c6e66 --- /dev/null +++ b/db/migrate/20190908031103_drop_related_tags_from_tags.rb @@ -0,0 +1,6 @@ +class DropRelatedTagsFromTags < ActiveRecord::Migration[6.0] + def change + remove_column :tags, :related_tags, :text + remove_column :tags, :related_tags_updated_at, :datetime + end +end diff --git a/db/structure.sql b/db/structure.sql index 49530414e..352a75b96 100644 --- a/db/structure.sql +++ b/db/structure.sql @@ -2880,8 +2880,6 @@ CREATE TABLE public.tags ( name character varying NOT NULL, post_count integer DEFAULT 0 NOT NULL, category integer DEFAULT 0 NOT NULL, - related_tags text, - related_tags_updated_at timestamp without time zone, created_at timestamp without time zone NOT NULL, updated_at timestamp without time zone NOT NULL, is_locked boolean DEFAULT false NOT NULL @@ -7316,6 +7314,7 @@ INSERT INTO "schema_migrations" (version) VALUES ('20190828005453'), ('20190829052629'), ('20190829055758'), -('20190902224045'); +('20190902224045'), +('20190908031103'); diff --git a/test/factories/tag.rb b/test/factories/tag.rb index 2fa0dc183..8a6b31d33 100644 --- a/test/factories/tag.rb +++ b/test/factories/tag.rb @@ -3,8 +3,6 @@ FactoryBot.define do name {"#{FFaker::Name.first_name.downcase}#{rand(1000)}"} post_count {0} category {Tag.categories.general} - related_tags {""} - related_tags_updated_at {Time.now} factory(:artist_tag) do category {Tag.categories.artist}