On Feb 3, 2011, at 2:57 AM, Albert Català <[email protected]> wrote:
Curtis j Schofield wrote in post #979342:
2011/2/1 Albert Catal <[email protected]>:
super(args)
end
def error(msg)
#also - this may give you an error
# i remember this as
msg = %%ERROR#{'-'*5}>#{msg}%
super
raises an error: [super: no superclass method `error' for
What I did, exactly is:
class Logger
def initialize(args=nil)
super(args)
end
def error(msg)
super("ERROR------------>"+msg)
end
end
this is in a file.rb in config/initializers/
and raises the error I said
Did you read my other response about class methods?
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google
Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-
[email protected].
To unsubscribe from this group, send email to [email protected]
.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en
.
--
You received this message because you are subscribed to the Google Groups "Ruby on
Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en.