in Hacking

A copy of has been removed from the module tree but is still active

I'm working on a rails website that requires me to specify a class in an initializer.

config/initializers

spree.searcher_class = MySearcherClass

I'm currently developing this searcher class. Every time I change this class I get the following message:

A copy of MySearcherClass has been removed from the module tree but is still active

This sucks big time! Because I need to restart my rails application every time I change something.

My workaround for the moment is this:

spree.searcher_class = class.new do
    def new(*args,&block)
      return MySearcherClass.new( *args, &block )
    end
  end
end

I'm not very keen on this, but it does the trick for now :)