]> source.dussan.org Git - vaadin-framework.git/commitdiff
[merge from 6.7] Remove duplicate code in constructor
authorAutomerge <automerge@vaadin.com>
Mon, 21 May 2012 17:06:20 +0000 (17:06 +0000)
committerAutomerge <automerge@vaadin.com>
Mon, 21 May 2012 17:06:20 +0000 (17:06 +0000)
svn changeset:23779/svn branch:6.8

src/com/vaadin/terminal/ClassResource.java

index fa196e90d9a08b7943923129028fac6488cfa0bf..e7419576f16425accc9fa879dda2df92a7683348 100644 (file)
@@ -60,13 +60,7 @@ public class ClassResource implements ApplicationResource, Serializable {
      *            the application this resource will be added to.
      */
     public ClassResource(String resourceName, Application application) {
-        associatedClass = application.getClass();
-        this.resourceName = resourceName;
-        this.application = application;
-        if (resourceName == null) {
-            throw new NullPointerException();
-        }
-        application.addResource(this);
+        this(application.getClass(), resourceName, application);
     }
 
     /**