You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by "Howard M. Lewis Ship (JIRA)" <de...@tapestry.apache.org> on 2008/05/04 18:28:55 UTC

[jira] Assigned: (TAPESTRY-2308) Don't create HttpSession when persisted property is null

     [ https://issues.apache.org/jira/browse/TAPESTRY-2308?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Howard M. Lewis Ship reassigned TAPESTRY-2308:
----------------------------------------------

    Assignee: Howard M. Lewis Ship

> Don't create HttpSession when persisted property is null
> --------------------------------------------------------
>
>                 Key: TAPESTRY-2308
>                 URL: https://issues.apache.org/jira/browse/TAPESTRY-2308
>             Project: Tapestry
>          Issue Type: Improvement
>          Components: tapestry-core
>    Affects Versions: 5.0.11
>            Reporter: Josh Canfield
>            Assignee: Howard M. Lewis Ship
>            Priority: Minor
>
> When persisting properties using "session" it would be nice if the session was only created after a non-null value was assigned to the property.
> It should be enough to add a simple guard in AbstractSessionPersistentFieldStrategy#postChange
>         Session session = _request.getSession(newValue != null);
>         if (session != null) {
>             session.setAttribute(builder.toString(), newValue);
>         }
> allowing existing session values to be replaced if the session exists, but not storing a value if no session exists.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org