From bbbedeeb890dd88023c8c5c85dcbd4d2144aa129 Mon Sep 17 00:00:00 2001 From: Carlos Antonio da Silva Date: Wed, 26 Jun 2013 20:15:35 -0300 Subject: Move delegation error constant to inside Module --- activesupport/lib/active_support/core_ext/module/delegation.rb | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'activesupport/lib/active_support/core_ext/module/delegation.rb') diff --git a/activesupport/lib/active_support/core_ext/module/delegation.rb b/activesupport/lib/active_support/core_ext/module/delegation.rb index 9d4b78e242..1aa72da743 100644 --- a/activesupport/lib/active_support/core_ext/module/delegation.rb +++ b/activesupport/lib/active_support/core_ext/module/delegation.rb @@ -1,4 +1,8 @@ class Module + # Error generated by +delegate+ when a method is called on +nil+ and +allow_nil+ + # option is not used. + class DelegationError < NoMethodError; end + # Provides a +delegate+ class method to easily expose contained objects' # public methods as your own. # @@ -194,5 +198,3 @@ class Module end end end - -class DelegationError < StandardError ; end -- cgit v1.2.3