mjgp2
1
I have a plugin which does something like this for different
associations:
belongs_to_klass.send(:belongs_to, belongs_to_name)
This works fine for the first page request in mongrel/webrick, but the
associations are lost on/by the next page request. Any ideas?
Thanks :o)
mjgp2
2
Matthew P. wrote:
I have a plugin which does something like this for different
associations:
belongs_to_klass.send(:belongs_to, belongs_to_name)
This works fine for the first page request in mongrel/webrick, but the
associations are lost on/by the next page request. Any ideas?
Thanks :o)
Heh, thought of the answer just after posting! In environment.rb, this
was the case:
config.cache_classes = false
So the classes were being scrubbed, but the plugin was not being called
again.
mjgp2
3
On 2006-09-20, at 13:18 , Matthew P. wrote:
I have a plugin which does something like this for different
associations:
belongs_to_klass.send(:belongs_to, belongs_to_name)
This works fine for the first page request in mongrel/webrick, but the
associations are lost on/by the next page request. Any ideas?
Test with the production environment. If it works there, then it’s a
problem with class reloading that happens in the development
environment.