Hi,
In my actions, I sometimes test for certain conditions by checking to see if the
session object contains a particular key, such as
if (session.containsKey("myObject")) {
System.out.println("myObject is " + ( (Integer) session.get("myObject")
).intValue() );
}
I've run into various problems where session.containsKey("myObject") returns true, but
session.get("myObject") returns null.
Is this a bug? Am I doing something that's causing this?
Now, a simple remedy would be to replace
if (session.containsKey("myObject")) {}
with
if (session.get("myObject")==null) {}
but that's just not pretty.
Btw, in my particular case, session.containsKey("myObject") should return false,
because the user had let the session expire on the browser. I just don't understand
why it returns true...
Thank you,
James
-------------------------------------------------------
The SF.Net email is sponsored by EclipseCon 2004
Premiere Conference on Open Tools Development and Integration
See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
http://www.eclipsecon.org/osdn
_______________________________________________
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork