Revert usage of File.separator

File.separator doesn't appear to work on Windows. It has to be "/", not "\".
See: https://github.com/bisq-network/bisq/pull/5909#pullrequestreview-827992563
This commit is contained in:
chimp1984 2021-12-09 13:13:37 -05:00
parent d74bffb595
commit 225b78317f
No known key found for this signature in database
GPG key ID: 9801B4EC591F90E3

View file

@ -123,7 +123,9 @@ public class BsqBlocksStorageService {
}
for (String fileName : fileNames) {
File destinationFile = new File(storageDir, fileName);
FileUtil.resourceToFile(resourceDir + File.separator + fileName, destinationFile);
// File.separator doesn't appear to work on Windows. It has to be "/", not "\".
// See: https://github.com/bisq-network/bisq/pull/5909#pullrequestreview-827992563
FileUtil.resourceToFile(resourceDir + "/" + fileName, destinationFile);
}
log.info("Copying {} resource files took {} ms", fileNames.size(), System.currentTimeMillis() - ts);
} catch (ResourceNotFoundException ignore) {