public Method

Fixture.find

There's no documentation for this item.

Source Code

# File active_record/fixtures.rb, line 803
def find
  klass = @class_name.is_a?(Class) ? @class_name : Object.const_get(@class_name) rescue nil
  if klass
    klass.find(self[klass.primary_key])
  else
    raise FixtureClassNotFound, "The class #{@class_name.inspect} was not found."
  end
end
Comments

Have your say
Please use Textile formatting (click here for a cheat sheet). Use <code/> and <pre/> for code samples.
Click here to login with OpenID to to post comments.