From 53b34e84762b7f2d6b641f99dadbb1eab42907ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Valim?= Date: Thu, 1 Jul 2010 17:07:48 +0200 Subject: Avoid calls to Rails::Application since this is not the official API. Your application should *always* reference your application const (as Blog::Application) and Rails.application should be used just internally. --- activesupport/lib/active_support/file_update_checker.rb | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'activesupport/lib/active_support') diff --git a/activesupport/lib/active_support/file_update_checker.rb b/activesupport/lib/active_support/file_update_checker.rb index 5f5b264eb9..cd658fe173 100644 --- a/activesupport/lib/active_support/file_update_checker.rb +++ b/activesupport/lib/active_support/file_update_checker.rb @@ -1,16 +1,15 @@ module ActiveSupport # This class is responsible to track files and invoke the given block # whenever one of these files are changed. For example, this class - # is used by Rails to reload routes whenever they are changed upon - # a new request. + # is used by Rails to reload the I18n framework whenever they are + # changed upon a new request. # - # routes_reloader = ActiveSupport::FileUpdateChecker.new(paths) do - # paths.each { |p| load(p) } - # Rails::Application.routes.reload! + # i18n_reloader = ActiveSupport::FileUpdateChecker.new(paths) do + # I18n.reload! # end # # ActionDispatch::Callbacks.to_prepare do - # routes_reloader.execute_if_updated + # i18n_reloader.execute_if_updated # end # class FileUpdateChecker -- cgit v1.2.3