about summary refs log tree commit diff
path: root/db
diff options
context:
space:
mode:
authorFire Demon <firedemon@creature.cafe>2020-11-23 23:10:05 -0600
committerFire Demon <firedemon@creature.cafe>2020-11-23 23:10:05 -0600
commit65a9abb315f18ac777f3d0e09b3f7399830ad243 (patch)
tree39712b50201749efad11dce09561d81f4bdcdb2f /db
parent7f5ba917563aa1c9a373d9dd3a6a29f73d81ee9a (diff)
Add user options to disable recipient verification, allow anonymous public access; rework private mode
Diffstat (limited to 'db')
-rw-r--r--db/migrate/20201123152231_add_no_verify_auth_to_accounts.rb7
-rw-r--r--db/migrate/20201123171722_add_allow_anonymous_to_accounts.rb5
-rw-r--r--db/migrate/20201124005733_remove_require_auth_from_accounts.rb7
-rw-r--r--db/schema.rb5
4 files changed, 22 insertions, 2 deletions
diff --git a/db/migrate/20201123152231_add_no_verify_auth_to_accounts.rb b/db/migrate/20201123152231_add_no_verify_auth_to_accounts.rb
new file mode 100644
index 000000000..38f5bc046
--- /dev/null
+++ b/db/migrate/20201123152231_add_no_verify_auth_to_accounts.rb
@@ -0,0 +1,7 @@
+class AddNoVerifyAuthToAccounts < ActiveRecord::Migration[5.2]
+  def change
+    safety_assured do
+      add_column :accounts, :no_verify_auth, :boolean, null: false, default: false
+    end
+  end
+end
diff --git a/db/migrate/20201123171722_add_allow_anonymous_to_accounts.rb b/db/migrate/20201123171722_add_allow_anonymous_to_accounts.rb
new file mode 100644
index 000000000..c7fdfba14
--- /dev/null
+++ b/db/migrate/20201123171722_add_allow_anonymous_to_accounts.rb
@@ -0,0 +1,5 @@
+class AddAllowAnonymousToAccounts < ActiveRecord::Migration[5.2]
+  def change
+    add_column :accounts, :allow_anonymous, :boolean, null: false, default: false
+  end
+end
diff --git a/db/migrate/20201124005733_remove_require_auth_from_accounts.rb b/db/migrate/20201124005733_remove_require_auth_from_accounts.rb
new file mode 100644
index 000000000..3f64b539a
--- /dev/null
+++ b/db/migrate/20201124005733_remove_require_auth_from_accounts.rb
@@ -0,0 +1,7 @@
+class RemoveRequireAuthFromAccounts < ActiveRecord::Migration[5.2]
+  def change
+    safety_assured do
+      remove_column :accounts, :require_auth, :boolean, null: false, default: false
+    end
+  end
+end
diff --git a/db/schema.rb b/db/schema.rb
index 273e942f5..346177241 100644
--- a/db/schema.rb
+++ b/db/schema.rb
@@ -10,7 +10,7 @@
 #
 # It's strongly recommended that you check this file into your version control system.
 
-ActiveRecord::Schema.define(version: 2020_11_19_035441) do
+ActiveRecord::Schema.define(version: 2020_11_24_005733) do
 
   # These are extensions that must be enabled in order to support this database
   enable_extension "plpgsql"
@@ -209,10 +209,11 @@ ActiveRecord::Schema.define(version: 2020_11_19_035441) do
     t.boolean "show_replies", default: true, null: false
     t.boolean "show_unlisted", default: true, null: false
     t.boolean "private", default: false, null: false
-    t.boolean "require_auth", default: false, null: false
     t.datetime "last_synced_at"
     t.datetime "sensitized_at"
     t.integer "suspension_origin"
+    t.boolean "no_verify_auth", default: false, null: false
+    t.boolean "allow_anonymous", default: false, null: false
     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 ["moved_to_account_id"], name: "index_accounts_on_moved_to_account_id"