You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by jd...@apache.org on 2006/11/04 14:56:30 UTC
svn commit: r471188 -
/incubator/wicket/trunk/wicket-examples/src/main/java/wicket/examples/source/SourcesPage.java
Author: jdonnerstag
Date: Sat Nov 4 05:56:29 2006
New Revision: 471188
URL: http://svn.apache.org/viewvc?view=rev&rev=471188
Log:
fixed NPE (see echo example)
Modified:
incubator/wicket/trunk/wicket-examples/src/main/java/wicket/examples/source/SourcesPage.java
Modified: incubator/wicket/trunk/wicket-examples/src/main/java/wicket/examples/source/SourcesPage.java
URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/wicket-examples/src/main/java/wicket/examples/source/SourcesPage.java?view=diff&rev=471188&r1=471187&r2=471188
==============================================================================
--- incubator/wicket/trunk/wicket-examples/src/main/java/wicket/examples/source/SourcesPage.java (original)
+++ incubator/wicket/trunk/wicket-examples/src/main/java/wicket/examples/source/SourcesPage.java Sat Nov 4 05:56:29 2006
@@ -314,8 +314,11 @@
public void onClick(AjaxRequestTarget target)
{
setName(getModelObjectAsString());
- target.addComponent(codePanel);
- target.addComponent(filename);
+ if (target != null)
+ {
+ target.addComponent(codePanel);
+ target.addComponent(filename);
+ }
}
};
new Label(link, "name", item.getModelObjectAsString());