Hi
I am setting up a new application, based on the simple template. I get this error whenever I oprn a browser and go to the application’s home url:
The variable: sessionReference is undefined in the request collection (private=false)
Then, if I refresh the browser, the problem goes away and everything behaves as normal.
I see that some other people have had this issue before but I don’t see any solutions.
I have attached my Application.cfc, handlers/Main.cfc and config/Coldbox.cfc. Can someone advise me please? Thanks.
Application.cfc (1.7 KB)
Main.cfc (2.8 KB)
Coldbox.cfc (2.99 KB)
PS. The same error occurs if I leave the browser until the session times-out and then hit refresh.
Where is that error happening? Is there a stack trace? That sounds like onSessionEnd, but I wouldn’t expect you to hit that with your browser.
Thanks!
~Brad
ColdBox/CommandBox Developer Advocate
Ortus Solutions, Corp
E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com
I’d have to see the code in your main handler to have a clue what it’s doing. Why are you referencing that variable? Where is it being set? What are the implicit events in your config?
Thanks!
~Brad
ColdBox/CommandBox Developer Advocate
Ortus Solutions, Corp
E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com
Hi Brad
I attached the Main handler to my original post.
bdw429s
January 20, 2017, 11:17pm
7
Yes, sorry. Here’s your problem right here:
sessionStartHandler = “Main.onSessionEnd”,
sessionEndHandler = “Main.onSessionStart”,
You’ve got your wires crossed.
Thanks!
~Brad
Hey Brad
Good spot! Thanks!
By the way, I copied that chunk of code from here: https://coldbox.ortusbooks.com/content/full/configuration/coldboxcfc/configuration_directives/coldbox.html . See the section on Implicit Event Settings.
Who do we tell so it can get changed?
Uh oh!! I fixed up the page and Gitbook is building now
Thanks!
~Brad
ColdBox/CommandBox Developer Advocate
Ortus Solutions, Corp
E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com