rubyonrailsin

A Ruby and Rails talk

Wednesday, March 31, 2010


[Rails] module loading issue

by rubyonrailsin 0 comments

Tag


Share this post:
Design Float
StumbleUpon
Reddit

Trying to keep things organized I created a directory under app called
modules. In my env file I did what I did for my other directories:

config.load_paths += Dir[ "#{RAILS_ROOT}/app/modules/**" ]

Here is the top of my module:

module Sanitize
module Html
def self.included(base)
base.extend(ClassMethods)
end

I have an initializer that does this:
include HtmlSanitize

When I boot up it says unitilialized constant "HtmlSanitize"

What am I missing?

--
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-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

No comments:

Post a Comment

Subscribe feeds via e-mail

Blog Archive