Methods are not visible... I'm sure this is an easy one

I’m adding methods to my models and for some reason all these new
methods are not invisible when I call them. For example,

def target_language
Language.find(self.target_language_id)
end

def bob
Language.find(self.origin_language_id)
end

I can call target_language, but when I call bob, I get "undefined
method. But it’s exactly the same! I restarted mongrel and still
every new method is just invisible. Why is this?

On 20 Dec 2007, at 15:15, Gavin wrote:

end
I think you’re going to have to show us some more information than this.

Fred

You are putting these INSIDE the class, right?

On Dec 20, 7:15 am, Gavin [email protected] wrote:

I’m adding methods to my models and for some reason all these new
methods are not invisible when I call them. For example,

Make some kind of syntax error in target_language, then call it.
That’ll at least make sure you’re changing the source you think you
are. It’ll also reveal if the class is just being cached.

///ark

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs