diff options
author | Jon Leighton <j@jonathanleighton.com> | 2011-04-04 00:07:45 +0100 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2011-04-12 19:46:04 -0700 |
commit | 5740d4ec0c16d68b82f440e74fd8b74ae3fe48e6 (patch) | |
tree | e8f0dff39f96658699b66749b4a257ba8ccfda9f /activerecord/test/models/pirate.rb | |
parent | fc9a04b6a69d6821a6f1601e3e0dd518300fa138 (diff) | |
download | rails-5740d4ec0c16d68b82f440e74fd8b74ae3fe48e6.tar.gz rails-5740d4ec0c16d68b82f440e74fd8b74ae3fe48e6.tar.bz2 rails-5740d4ec0c16d68b82f440e74fd8b74ae3fe48e6.zip |
Deprecated support for passing hashes and relations to default_scope, in favour of defining a 'default_scope' class method in the model. See the CHANGELOG for more details.
Diffstat (limited to 'activerecord/test/models/pirate.rb')
-rw-r--r-- | activerecord/test/models/pirate.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/test/models/pirate.rb b/activerecord/test/models/pirate.rb index 0d3f62bb33..5e0f5323e6 100644 --- a/activerecord/test/models/pirate.rb +++ b/activerecord/test/models/pirate.rb @@ -34,7 +34,7 @@ class Pirate < ActiveRecord::Base :after_remove => proc {|p,b| p.ship_log << "after_removing_proc_bird_#{b.id}"} has_many :birds_with_reject_all_blank, :class_name => "Bird" - has_one :bulb, :foreign_key => :car_id + has_one :foo_bulb, :foreign_key => :car_id, :class_name => "Bulb", :conditions => { :name => 'foo' } accepts_nested_attributes_for :parrots, :birds, :allow_destroy => true, :reject_if => proc { |attributes| attributes.empty? } accepts_nested_attributes_for :ship, :allow_destroy => true, :reject_if => proc { |attributes| attributes.empty? } |