onSessionStart in Module

Hello Guys,

I have a handler event inside a module I need to fire onSessionStart() but I can’t seem to get it working.

If I place the method inside a handler for the main application it works perfectly. However if I try the config setting as either:

sessionStartHandler = “modules.saas.handlers.security.onSessionStart”,

or

sessionStartHandler = “security.onSessionStart”,

Then I get an exception saying that it is not a valid registered event.

Can anyone offer any advice on this? I’ve been trawling through the docs and couldn’t find anything.

Thanks,

Robert

To answer my own question:

I was laying awake at 4am this morning pondering this, and thought perhaps an interceptor would be best.

Dropped an interceptor into the module this morning with SessionStart defined, works like a charm.

Robert

Lol, did I not tweet that you too an hour or so agoJ

Anyway you got to love interceptors though.

Regards,

Andrew Scott

http://www.andyscott.id.au/

Haha you did indeed bud! I tweeted you back!

It’s a very nice way of handling things. I have a bunch of enhancements to add to the same interceptor too.

Thanks mate.

Robert

Yes the main app defines the main event handlers but for modules I
would suggest interceptors.