diff options
author | Jon Leighton <j@jonathanleighton.com> | 2011-05-23 12:02:06 +0100 |
---|---|---|
committer | Jon Leighton <j@jonathanleighton.com> | 2011-05-23 20:25:44 +0100 |
commit | d411c85a65baaf4ed268b1b1bb4df408cee4981a (patch) | |
tree | b054f3a4b95748b10e70c8d3a952e3b829366f2f /railties/lib/rails | |
parent | a5fb1c61755f03a8c75b0a434fb2aca57502293b (diff) | |
download | rails-d411c85a65baaf4ed268b1b1bb4df408cee4981a.tar.gz rails-d411c85a65baaf4ed268b1b1bb4df408cee4981a.tar.bz2 rails-d411c85a65baaf4ed268b1b1bb4df408cee4981a.zip |
Replace references to ActiveSupport::SecureRandom with just SecureRandom, and require 'securerandom' from the stdlib when active support is required.
Diffstat (limited to 'railties/lib/rails')
-rw-r--r-- | railties/lib/rails/generators/rails/app/app_generator.rb | 2 | ||||
-rw-r--r-- | railties/lib/rails/tasks/misc.rake | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/railties/lib/rails/generators/rails/app/app_generator.rb b/railties/lib/rails/generators/rails/app/app_generator.rb index 5f9fb9685c..242677cc65 100644 --- a/railties/lib/rails/generators/rails/app/app_generator.rb +++ b/railties/lib/rails/generators/rails/app/app_generator.rb @@ -272,7 +272,7 @@ module Rails end def app_secret - ActiveSupport::SecureRandom.hex(64) + SecureRandom.hex(64) end def mysql_socket diff --git a/railties/lib/rails/tasks/misc.rake b/railties/lib/rails/tasks/misc.rake index e505b8c338..53e479b924 100644 --- a/railties/lib/rails/tasks/misc.rake +++ b/railties/lib/rails/tasks/misc.rake @@ -10,7 +10,7 @@ end desc 'Generate a cryptographically secure secret key (this is typically used to generate a secret for cookie sessions).' task :secret do require 'active_support/secure_random' - puts ActiveSupport::SecureRandom.hex(64) + puts SecureRandom.hex(64) end desc 'List versions of all Rails frameworks and the environment' |