aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord
diff options
context:
space:
mode:
authorJosé Valim and Mikel Lindsaar <pair@programming.com>2010-01-25 09:50:01 +1100
committerJosé Valim and Mikel Lindsaar <pair@programming.com>2010-01-25 09:50:01 +1100
commit4e96442c4e404141830b2d7f0d850b6556190b39 (patch)
treea3ca088ad9d68b5be9ace4d431375bb3fd4ea045 /activerecord
parenta74a655648618a6ed568b9b4ef3a17a8970e7774 (diff)
parent396003fc48d7c0ba206ad059646c7414bee22a36 (diff)
downloadrails-4e96442c4e404141830b2d7f0d850b6556190b39.tar.gz
rails-4e96442c4e404141830b2d7f0d850b6556190b39.tar.bz2
rails-4e96442c4e404141830b2d7f0d850b6556190b39.zip
Merge branch 'master' of git://github.com/rails/rails
Conflicts: actionmailer/lib/action_mailer/mail_helper.rb railties/lib/rails/configuration.rb
Diffstat (limited to 'activerecord')
-rw-r--r--activerecord/lib/active_record/railtie.rb12
1 files changed, 6 insertions, 6 deletions
diff --git a/activerecord/lib/active_record/railtie.rb b/activerecord/lib/active_record/railtie.rb
index bc06333f1c..7b6d792931 100644
--- a/activerecord/lib/active_record/railtie.rb
+++ b/activerecord/lib/active_record/railtie.rb
@@ -8,7 +8,7 @@ require "rails"
module ActiveRecord
class Railtie < Rails::Railtie
- plugin_name :active_record
+ railtie_name :active_record
rake_tasks do
load "active_record/railties/databases.rake"
@@ -18,6 +18,11 @@ module ActiveRecord
require "active_record/railties/subscriber"
subscriber ActiveRecord::Railties::Subscriber.new
+ initializer "active_record.initialize_timezone" do
+ ActiveRecord::Base.time_zone_aware_attributes = true
+ ActiveRecord::Base.default_timezone = :utc
+ end
+
initializer "active_record.set_configs" do |app|
app.config.active_record.each do |k,v|
ActiveRecord::Base.send "#{k}=", v
@@ -31,11 +36,6 @@ module ActiveRecord
ActiveRecord::Base.establish_connection
end
- initializer "active_record.initialize_timezone" do
- ActiveRecord::Base.time_zone_aware_attributes = true
- ActiveRecord::Base.default_timezone = :utc
- end
-
# Expose database runtime to controller for logging.
initializer "active_record.log_runtime" do |app|
require "active_record/railties/controller_runtime"