Skip to content

Commit

Permalink
Create and run migration to drop sessions table
Browse files Browse the repository at this point in the history
Our app is using the cookie_store https://github.com/portagenetwork/roadmap/blob/deployment-portage/config/initializers/session_store.rb. As a result, the sessions table is no longer needed.
  • Loading branch information
aaronskiba committed Aug 20, 2024
1 parent 9a9e6e2 commit 124bc52
Show file tree
Hide file tree
Showing 2 changed files with 112 additions and 107 deletions.
11 changes: 11 additions & 0 deletions db/migrate/20240820190548_drop_sessions_table.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
class DropSessionsTable < ActiveRecord::Migration[6.1]
def up
drop_table :sessions
end

def down
# rollback will the execute the initial migration code written to create the sessions table
require Rails.root.join('db/migrate/20181024120747_add_sessions_table.rb')
AddSessionsTable.new.change
end
end
Loading

0 comments on commit 124bc52

Please sign in to comment.