mirror of
https://github.com/discourse/discourse.git
synced 2024-12-24 06:33:53 +08:00
30990006a9
This reduces chances of errors where consumers of strings mutate inputs and reduces memory usage of the app. Test suite passes now, but there may be some stuff left, so we will run a few sites on a branch prior to merging
19 lines
545 B
Ruby
19 lines
545 B
Ruby
# frozen_string_literal: true
|
|
|
|
class CreateDirectoryItems < ActiveRecord::Migration[4.2]
|
|
def change
|
|
create_table :directory_items, force: true do |t|
|
|
t.integer :period_type, null: false
|
|
t.references :user, null: false
|
|
t.integer :likes_received, null: false
|
|
t.integer :likes_given, null: false
|
|
t.integer :topics_entered, null: false
|
|
t.integer :topic_count, null: false
|
|
t.integer :post_count, null: false
|
|
t.timestamps null: true
|
|
end
|
|
|
|
add_index :directory_items, :period_type
|
|
end
|
|
end
|