From c90971644a90372cfa56dac8b9b2ce709a6e7267 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20Strza=C5=82kowski?= Date: Fri, 5 Jul 2013 13:30:22 +0200 Subject: Revert "Rename abstract_controller/rendering. to errors.rb" This reverts commit 6fe91ec5008838338e54ab8570f7c95ee0cdd8e8. --- actionpack/lib/abstract_controller.rb | 2 +- actionpack/lib/abstract_controller/errors.rb | 9 --------- actionpack/lib/abstract_controller/rendering.rb | 9 +++++++++ 3 files changed, 10 insertions(+), 10 deletions(-) delete mode 100644 actionpack/lib/abstract_controller/errors.rb create mode 100644 actionpack/lib/abstract_controller/rendering.rb (limited to 'actionpack') diff --git a/actionpack/lib/abstract_controller.rb b/actionpack/lib/abstract_controller.rb index 5c07753075..909b438a41 100644 --- a/actionpack/lib/abstract_controller.rb +++ b/actionpack/lib/abstract_controller.rb @@ -10,7 +10,7 @@ module AbstractController autoload :Base autoload :Callbacks autoload :Collector - autoload :DoubleRenderError, "abstract_controller/errors.rb" + autoload :DoubleRenderError, "abstract_controller/rendering.rb" autoload :Helpers autoload :Logger autoload :Translation diff --git a/actionpack/lib/abstract_controller/errors.rb b/actionpack/lib/abstract_controller/errors.rb deleted file mode 100644 index 8997207550..0000000000 --- a/actionpack/lib/abstract_controller/errors.rb +++ /dev/null @@ -1,9 +0,0 @@ -module AbstractController - class DoubleRenderError < Error - DEFAULT_MESSAGE = "Render and/or redirect were called multiple times in this action. Please note that you may only call render OR redirect, and at most once per action. Also note that neither redirect nor render terminate execution of the action, so if you want to exit an action after redirecting, you need to do something like \"redirect_to(...) and return\"." - - def initialize(message = nil) - super(message || DEFAULT_MESSAGE) - end - end -end diff --git a/actionpack/lib/abstract_controller/rendering.rb b/actionpack/lib/abstract_controller/rendering.rb new file mode 100644 index 0000000000..8997207550 --- /dev/null +++ b/actionpack/lib/abstract_controller/rendering.rb @@ -0,0 +1,9 @@ +module AbstractController + class DoubleRenderError < Error + DEFAULT_MESSAGE = "Render and/or redirect were called multiple times in this action. Please note that you may only call render OR redirect, and at most once per action. Also note that neither redirect nor render terminate execution of the action, so if you want to exit an action after redirecting, you need to do something like \"redirect_to(...) and return\"." + + def initialize(message = nil) + super(message || DEFAULT_MESSAGE) + end + end +end -- cgit v1.2.3