Skip to content

Commit

Permalink
Migration can not rolled back as sessions are now secure hashes. Than…
Browse files Browse the repository at this point in the history
…ks to @n00dle.

Co-authored-by: n00dle <richardwu@gmail.com>
  • Loading branch information
thorsteneckel and n00dle authored Mar 10, 2021
1 parent 90a4cb2 commit 4b705d9
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -119,9 +119,13 @@ The following example Active Record Migration will work for the default setup of
```ruby
# db/migrate/20210310083511_cve201925025_mitigation.rb
class Cve201925025Mitigation < ActiveRecord::Migration[5.2]
def change
def up
ActionDispatch::Session::ActiveRecordStore.session_class.find_each(&:secure!)
end

def down
# no-op
end
end
```

Expand Down

0 comments on commit 4b705d9

Please sign in to comment.