fixes error when can't unmarshal session contents #3298
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi there,
when Marshal.load can't read an object, it raises an ArgumentError. This is happening after migrating from rails 3.0.x to 3.1, when the session contains a FlashHash object. That's because FlashHash doesn't inherit from Hash anymore (see 76c2ea7) - related issue: #2509
I couldn't write a test to reproduce it, unfortunately - and I couldn't find any test exercising this portion of the code. Maybe somebody more used to the codebase?
Best!
Bruno