Deep copy all file options when cloning project
authorDavid ‘Bombe’ Roden <bombe@freenetproject.org>
Tue, 16 Jun 2015 04:37:17 +0000 (06:37 +0200)
committerDavid ‘Bombe’ Roden <bombe@freenetproject.org>
Tue, 16 Jun 2015 04:37:17 +0000 (06:37 +0200)
src/main/java/de/todesbaum/jsite/application/Project.java

index 836a2cd..d9146a1 100644 (file)
@@ -94,7 +94,9 @@ public class Project implements Comparable<Project> {
                lastInsertionTime = project.lastInsertionTime;
                alwaysForceInserts = project.alwaysForceInserts;
                ignoreHiddenFiles = project.ignoreHiddenFiles;
-               fileOptions = new HashMap<String, FileOption>(project.fileOptions);
+               for (Entry<String, FileOption> fileOption : fileOptions.entrySet()) {
+                       fileOptions.put(fileOption.getKey(), new FileOption(fileOption.getValue()));
+               }
        }
 
        /**