Add ability to manage which websites can credit you in link previews (#31819)
This commit is contained in:
		@@ -0,0 +1,7 @@
 | 
			
		||||
# frozen_string_literal: true
 | 
			
		||||
 | 
			
		||||
class AddAttributionDomainsToAccounts < ActiveRecord::Migration[7.1]
 | 
			
		||||
  def change
 | 
			
		||||
    add_column :accounts, :attribution_domains, :string, array: true, default: []
 | 
			
		||||
  end
 | 
			
		||||
end
 | 
			
		||||
@@ -10,7 +10,7 @@
 | 
			
		||||
#
 | 
			
		||||
# It's strongly recommended that you check this file into your version control system.
 | 
			
		||||
 | 
			
		||||
ActiveRecord::Schema[7.1].define(version: 2024_08_08_125420) do
 | 
			
		||||
ActiveRecord::Schema[7.1].define(version: 2024_09_09_014637) do
 | 
			
		||||
  # These are extensions that must be enabled in order to support this database
 | 
			
		||||
  enable_extension "plpgsql"
 | 
			
		||||
 | 
			
		||||
@@ -200,6 +200,7 @@ ActiveRecord::Schema[7.1].define(version: 2024_08_08_125420) do
 | 
			
		||||
    t.datetime "reviewed_at", precision: nil
 | 
			
		||||
    t.datetime "requested_review_at", precision: nil
 | 
			
		||||
    t.boolean "indexable", default: false, null: false
 | 
			
		||||
    t.string "attribution_domains", default: [], array: true
 | 
			
		||||
    t.index "(((setweight(to_tsvector('simple'::regconfig, (display_name)::text), 'A'::\"char\") || setweight(to_tsvector('simple'::regconfig, (username)::text), 'B'::\"char\")) || setweight(to_tsvector('simple'::regconfig, (COALESCE(domain, ''::character varying))::text), 'C'::\"char\")))", name: "search_index", using: :gin
 | 
			
		||||
    t.index "lower((username)::text), COALESCE(lower((domain)::text), ''::text)", name: "index_accounts_on_username_and_domain_lower", unique: true
 | 
			
		||||
    t.index ["domain", "id"], name: "index_accounts_on_domain_and_id"
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user