Sven Meier created WICKET-5040:
----------------------------------

             Summary: Session.exists() returns false when ThreadContext#session 
is not set to current session
                 Key: WICKET-5040
                 URL: https://issues.apache.org/jira/browse/WICKET-5040
             Project: Wicket
          Issue Type: Bug
          Components: wicket
    Affects Versions: 6.5.0
            Reporter: Sven Meier
            Assignee: Sven Meier


There are several places in Wicket which check for the existence of a Session 
before actually getting a reference to it, e.g. FeedbackCollector:

        public final List<FeedbackMessage> collect(final IFeedbackMessageFilter 
filter)
        {
                ...
                if (includeSession && Session.exists())
                {
                        
messages.addAll(Session.get().getFeedbackMessages().messages(filter));
                }
        }

If no one has called Session#get(), all calls to Session#exists() return false 
although a session might exist in the session store, i.e. it might just not be 
set to ThreadContext#session already.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to