20200516183822_create_one_time_keys.rb 400 B

1234567891011121314
  1. # frozen_string_literal: true
  2. class CreateOneTimeKeys < ActiveRecord::Migration[5.2]
  3. def change
  4. create_table :one_time_keys do |t|
  5. t.references :device, foreign_key: { on_delete: :cascade }
  6. t.string :key_id, default: '', null: false, index: :unique
  7. t.text :key, default: '', null: false
  8. t.text :signature, default: '', null: false
  9. t.timestamps
  10. end
  11. end
  12. end