diff options
Diffstat (limited to 'activemodel/lib/active_model')
-rw-r--r-- | activemodel/lib/active_model/observing.rb | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/activemodel/lib/active_model/observing.rb b/activemodel/lib/active_model/observing.rb index 7a910d18e7..cd8eb357de 100644 --- a/activemodel/lib/active_model/observing.rb +++ b/activemodel/lib/active_model/observing.rb @@ -187,8 +187,7 @@ module ActiveModel def observe(*models) models.flatten! models.collect! { |model| model.respond_to?(:to_sym) ? model.to_s.camelize.constantize : model } - remove_possible_method(:observed_classes) - define_method(:observed_classes) { models } + redefine_method(:observed_classes) { models } end # Returns an array of Classes to observe. |