Can't access session from helper?!

Hi,

I’m receiving this pretty standard error message:

undefined local variable or method `session’ for
ApplicantHelper::Filter:Class

All my searches have returned results where the developer is trying to
access the session from the model. In this case, it’s just a helper
class. Do I have to inherit from ActionController::Base and therefore
make the helper a controller? Is there another way?

Thanks,

Michael

Michael H. wrote:

make the helper a controller? Is there another way?
Pass it in as a parameter to the method.


Michael W.

You should have access to everything in your controller from the
helper. It looks as though you’re trying to access session from a
submodule of the helper which could be a problem.

Maybe you could try adding this to your controller:

helper ApplicantHelper::Filter