Browse Source

allow recursion by default for data files paths

Nicolas Cannasse 5 years ago
parent
commit
6f56ca2f35
1 changed files with 8 additions and 1 deletions
  1. 8 1
      hide/comp/cdb/DataFiles.hx

+ 8 - 1
hide/comp/cdb/DataFiles.hx

@@ -107,7 +107,14 @@ class DataFiles {
 				}
 				var reg = new EReg("^"+part.split(".").join("\\.").split("*").join(".*")+"$","");
 				for( f in sys.FileSystem.readDirectory(dir) ) {
-					if( !reg.match(f) ) continue;
+					if( !reg.match(f) ) {
+						if( sys.FileSystem.isDirectory(dir+"/"+f) ) {
+							curPath.push(f);
+							gatherRec(curPath,i-1);
+							curPath.pop();
+						}
+						continue;
+					}
 					curPath.push(f);
 					gatherRec(curPath,i);
 					curPath.pop();