From af8a1309bde2a85bd94d06f3f152ae6355677095 Mon Sep 17 00:00:00 2001 From: Fire Demon Date: Fri, 17 Jul 2020 19:56:35 -0500 Subject: [Feature] Introduce nest_level attribute to posts and API to help apps visualize nesting in threads --- db/migrate/20200717014609_add_nest_level_to_statuses.rb | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 db/migrate/20200717014609_add_nest_level_to_statuses.rb (limited to 'db/migrate/20200717014609_add_nest_level_to_statuses.rb') diff --git a/db/migrate/20200717014609_add_nest_level_to_statuses.rb b/db/migrate/20200717014609_add_nest_level_to_statuses.rb new file mode 100644 index 000000000..0b2196ad6 --- /dev/null +++ b/db/migrate/20200717014609_add_nest_level_to_statuses.rb @@ -0,0 +1,7 @@ +class AddNestLevelToStatuses < ActiveRecord::Migration[5.2] + def change + safety_assured do + add_column :statuses, :nest_level, :integer, limit: 1, null: false, default: 0 + end + end +end -- cgit