mirror of
https://github.com/PaperMC/Velocity.git
synced 2026-02-19 15:37:42 +01:00
Fix localization loading from JAR
This commit is contained in:
@@ -48,8 +48,7 @@ public class FileSystemUtils {
|
|||||||
.getProtectionDomain().getCodeSource().getLocation().getPath());
|
.getProtectionDomain().getCodeSource().getLocation().getPath());
|
||||||
|
|
||||||
if (file.isFile()) { // jar
|
if (file.isFile()) { // jar
|
||||||
URI uri = file.toURI();
|
try (FileSystem fileSystem = FileSystems.newFileSystem(file.toPath(), null)) {
|
||||||
try (FileSystem fileSystem = FileSystems.newFileSystem(uri, Collections.emptyMap())) {
|
|
||||||
Path toVisit = fileSystem.getPath(path.toString());
|
Path toVisit = fileSystem.getPath(path.toString());
|
||||||
if (Files.exists(toVisit)) {
|
if (Files.exists(toVisit)) {
|
||||||
consumer.accept(toVisit);
|
consumer.accept(toVisit);
|
||||||
|
|||||||
Reference in New Issue
Block a user