about summary refs log tree commit diff
path: root/db
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2016-09-20 00:39:03 +0200
committerEugen Rochko <eugen@zeonfederated.com>2016-09-20 00:43:36 +0200
commit059ebbf48dc56971b88e26a15303a75643de8b98 (patch)
treef0d46b941f298912094fe5a87b192d6fa8d4d304 /db
parent1245ee42fb9f689ffa4956f42f44a7ab75e19075 (diff)
Separate PuSH subscriptions from following, add mastodon:push:refresh task,
respect hub.lease_seconds (fix #46)
Diffstat (limited to 'db')
-rw-r--r--db/migrate/20160919221059_add_subscription_expires_at_to_accounts.rb5
-rw-r--r--db/schema.rb27
2 files changed, 19 insertions, 13 deletions
diff --git a/db/migrate/20160919221059_add_subscription_expires_at_to_accounts.rb b/db/migrate/20160919221059_add_subscription_expires_at_to_accounts.rb
new file mode 100644
index 000000000..5fd7f39e6
--- /dev/null
+++ b/db/migrate/20160919221059_add_subscription_expires_at_to_accounts.rb
@@ -0,0 +1,5 @@
+class AddSubscriptionExpiresAtToAccounts < ActiveRecord::Migration[5.0]
+  def change
+    add_column :accounts, :subscription_expires_at, :datetime, null: true, default: nil
+  end
+end
diff --git a/db/schema.rb b/db/schema.rb
index 4a3078e64..3179942c0 100644
--- a/db/schema.rb
+++ b/db/schema.rb
@@ -10,26 +10,26 @@
 #
 # It's strongly recommended that you check this file into your version control system.
 
-ActiveRecord::Schema.define(version: 20160905150353) do
+ActiveRecord::Schema.define(version: 20160919221059) do
 
   # These are extensions that must be enabled in order to support this database
   enable_extension "plpgsql"
 
   create_table "accounts", force: :cascade do |t|
-    t.string   "username",            default: "", null: false
+    t.string   "username",                default: "", null: false
     t.string   "domain"
-    t.string   "verify_token",        default: "", null: false
-    t.string   "secret",              default: "", null: false
+    t.string   "verify_token",            default: "", null: false
+    t.string   "secret",                  default: "", null: false
     t.text     "private_key"
-    t.text     "public_key",          default: "", null: false
-    t.string   "remote_url",          default: "", null: false
-    t.string   "salmon_url",          default: "", null: false
-    t.string   "hub_url",             default: "", null: false
-    t.datetime "created_at",                       null: false
-    t.datetime "updated_at",                       null: false
-    t.text     "note",                default: "", null: false
-    t.string   "display_name",        default: "", null: false
-    t.string   "uri",                 default: "", null: false
+    t.text     "public_key",              default: "", null: false
+    t.string   "remote_url",              default: "", null: false
+    t.string   "salmon_url",              default: "", null: false
+    t.string   "hub_url",                 default: "", null: false
+    t.datetime "created_at",                           null: false
+    t.datetime "updated_at",                           null: false
+    t.text     "note",                    default: "", null: false
+    t.string   "display_name",            default: "", null: false
+    t.string   "uri",                     default: "", null: false
     t.string   "url"
     t.string   "avatar_file_name"
     t.string   "avatar_content_type"
@@ -40,6 +40,7 @@ ActiveRecord::Schema.define(version: 20160905150353) do
     t.integer  "header_file_size"
     t.datetime "header_updated_at"
     t.string   "avatar_remote_url"
+    t.datetime "subscription_expires_at"
     t.index ["username", "domain"], name: "index_accounts_on_username_and_domain", unique: true, using: :btree
   end