From: "Jesús Gabriel y Galán" Date: 2009-11-21T03:33:25+09:00 Subject: Re: Re-opening an existing module and changing a method On Fri, Nov 20, 2009 at 1:47 PM, Aldric Giacomoni wrote: > Julian Leviston wrote: >> You're doing instance methods when you really want class methods. >> >> Good time to google the difference if you don't already know. >> > > Is this a new insight, or is this just putting words to what Jesus > already helped me discover (and hack) ? Well, people usually call class methods to methods that are defined in the singleton class of a class. In this case it could be a bit confusing, since we are not talking about a class but a Module. So I would call it a module method (or module function). > Instance method : Customer.new.phone # (probably yields an error : phone > number not set) > Class method : Customer.find(:first) # (Rails-style) > > Right ? Right, but it would be more clear to say module method, in my opinion. Jesus.