PERF: added missing indexes for pinned topics
This commit is contained in:
parent
738f2cb72c
commit
8c7cce1bfc
|
@ -0,0 +1,6 @@
|
|||
class AddPinnedIndexes < ActiveRecord::Migration
|
||||
def change
|
||||
add_index :topics, :pinned_globally, where: 'pinned_globally'
|
||||
add_index :topics, :pinned_at, where: 'pinned_at IS NOT NULL'
|
||||
end
|
||||
end
|
Loading…
Reference in New Issue