incubator-sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cziege...@apache.org
Subject svn commit: r1125254 - /sling/trunk/installer/providers/jcr/src/main/java/org/apache/sling/installer/provider/jcr/impl/JcrInstaller.java
Date Fri, 20 May 2011 06:40:20 GMT
Author: cziegeler
Date: Fri May 20 06:40:20 2011
New Revision: 1125254

URL: http://svn.apache.org/viewvc?rev=1125254&view=rev
Log:
SLING-2031 : Use bundle location to create path for persisting new configurations

Modified:
    sling/trunk/installer/providers/jcr/src/main/java/org/apache/sling/installer/provider/jcr/impl/JcrInstaller.java

Modified: sling/trunk/installer/providers/jcr/src/main/java/org/apache/sling/installer/provider/jcr/impl/JcrInstaller.java
URL: http://svn.apache.org/viewvc/sling/trunk/installer/providers/jcr/src/main/java/org/apache/sling/installer/provider/jcr/impl/JcrInstaller.java?rev=1125254&r1=1125253&r2=1125254&view=diff
==============================================================================
--- sling/trunk/installer/providers/jcr/src/main/java/org/apache/sling/installer/provider/jcr/impl/JcrInstaller.java
(original)
+++ sling/trunk/installer/providers/jcr/src/main/java/org/apache/sling/installer/provider/jcr/impl/JcrInstaller.java
Fri May 20 06:40:20 2011
@@ -298,15 +298,13 @@ public class JcrInstaller implements Eve
 
         // setup default path for new configurations
         this.newConfigPath = OsgiUtil.toString(context.getProperties().get(PROP_NEW_CONFIG_PATH),
DEFAULT_NEW_CONFIG_PATH);
-        final boolean postSlash = !newConfigPath.endsWith("/");
-        if ( postSlash ) {
+        final boolean postSlash = newConfigPath.endsWith("/");
+        if ( !postSlash ) {
             this.newConfigPath = newConfigPath.concat("/");
         }
-        final boolean preSlash = !newConfigPath.startsWith("/");
-        if ( preSlash ) {
-            this.newConfigPath = this.folderNameFilter.getRootPaths()[0] + "/" + this.newConfigPath;
-        } else {
-            this.newConfigPath = this.newConfigPath;
+        final boolean preSlash = newConfigPath.startsWith("/");
+        if ( !preSlash ) {
+            this.newConfigPath = this.folderNameFilter.getRootPaths()[0] + '/' + this.newConfigPath;
         }
 
         backgroundThread = new StoppableThread();



Mime
View raw message