DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=7097>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=7097

when bean has null value for PresentTag exception is saved, even though value is 
cleared

           Summary: when bean has null value for PresentTag exception is
                    saved, even though value is cleared
           Product: Struts
           Version: 1.0.2 Final
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: Custom Tags
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


Here is my jsp example:
  <logic:notPresent name="org.apache.struts.action.EXCEPTION">
  <p>Could not locate reason for error.</p>
  </logic:notPresent>

  <logic:present name="org.apache.struts.action.EXCEPTION">
  <p>An Error Occurred:<br>
  </logic:present>

Granted this is probably not the correct use of finding errors,
it does illustrate one problem.

  In the first notPresent tag, the bean is checked for, but not
found.  However, in the process of checking for the bean (via
'RequestUtils.lookup()' an exception is throw and saved).  Now
when I meet the following Present tag, the bean does have a value,
namely the exception that was saved.

Here is the code (around line 141) of PresentTag.java

            try {
                value =
                    RequestUtils.lookup(pageContext, name, property, scope);
            } catch (JspException e) {
                value = null;
            }

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to