This project is archived and is in readonly mode.

#5072 ✓resolved
Łukasz Strzałkowski

[PATCH] Warning about method redefined in active_model

Reported by Łukasz Strzałkowski | July 8th, 2010 @ 08:39 PM

When runnign test suite there are warnings:


/Users/strzalek/projects/ruby/rails_source/activemodel/lib/active_model/observing.rb:161: warning: method redefined; discarding old observed_classes
/Users/strzalek/projects/ruby/rails_source/activemodel/lib/active_model/observing.rb:161: warning: previous definition of observed_classes was here
/Users/strzalek/projects/ruby/rails_source/activemodel/lib/active_model/observing.rb:161: warning: method redefined; discarding old observed_classes
/Users/strzalek/projects/ruby/rails_source/activemodel/lib/active_model/observing.rb:161: warning: previous definition of observed_classes was here
/Users/strzalek/projects/ruby/rails_source/activemodel/lib/active_model/observing.rb:161: warning: method redefined; discarding old observed_classes
/Users/strzalek/projects/ruby/rails_source/activemodel/lib/active_model/observing.rb:161: warning: previous definition of observed_classes was here
/Users/strzalek/projects/ruby/rails_source/activemodel/lib/active_model/observing.rb:161: warning: method redefined; discarding old observed_classes
/Users/strzalek/projects/ruby/rails_source/activemodel/lib/active_model/observing.rb:161: warning: previous definition of observed_classes was here

There are 2 ways to avoid this warning. First is to alias old method, second is to remove it. As it isn't no longer used I think it can be removed.

Patch attached.

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

People watching this ticket

Attachments

Tags

Referenced by

Pages