Skip to content

Commit c464b69

Browse files
committed
Error in directory list fetch
On Windows directory listing API fails due to unsupported char colon : in the temporary file name. Removed colon character from timestamp
1 parent e27669e commit c464b69

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/main/java/org/openrefine/extensions/files/importer/FilesImportingController.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ public void doPost(HttpServletRequest request, HttpServletResponse response)
8282

8383
private void getDirectoryHierarchy(HttpServletRequest request, HttpServletResponse response, Properties parameters) throws ServletException, IOException {
8484
String dirPath = parameters.getProperty("dirPath");
85-
String fileName = "directoryList_OR_".concat(Instant.now().toString());
85+
String fileName = "directoryList_OR_".concat(Instant.now().toString().replace(":", ""));
8686
Path outputFile = Files.createTempFile(fileName, ".json");
8787
FilesImporter.generateDirectoryTree(dirPath, outputFile);
8888
respondJSON(response, Files.readString(outputFile));

0 commit comments

Comments
 (0)