On Jan 11, 2008, at 12:22 AM, rubynuby wrote:
still it suggests my application_helper.rb is being loaded multiple
times per request. is that normal? doesn’t seem efficient.
No, no, you shouldn’t be throwing any defined? like that. One uses
defined? when it makes sense in her context, not to hide a suspicious
What you are seeing is something that shouldn’t happen, so the right
thing to do is to discover why it is happening and fix it.
I think a trick to debug that could be to throw
RAILS_DEFAULT_LOGGER.debug(caller.join("\n")) if defined?
SOME_CONSTANT = value
in the helper module. There we use defined? to print the execution
stack just in the second run.