Created
July 17, 2012 10:13
-
-
Save javiertoledo/3128574 to your computer and use it in GitHub Desktop.
Hack to avoid gem compatibility nightmare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# If you're having this exception in Rails >=3.2.X, on Ruby >1.9.X.. | |
# | |
# uninitialized constant ActiveSupport::SecureRandom | |
# | |
# ..and you don't want to debug half dozen of gems until you | |
# find which one is causing the error, you can use this hack | |
# as Ruby's SecureRandom API is 100% compatible with the | |
# Rails <3.2 ActiveSupport::SecureRandom API. | |
# | |
# This is absolute uglyness, but works and I wont tell nobody | |
# that you are so lazy you used it ;-) | |
ActiveSupport::SecureRandom = SecureRandom |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment