From 953dcb50cbd2799ba600570bec51ea7f80b20449 Mon Sep 17 00:00:00 2001 From: Dmitry Isaenko Date: Fri, 6 Nov 2020 22:29:09 +0300 Subject: [PATCH] Rally fix #81 --- src/main/java/nsusbloader/FilesHelper.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/main/java/nsusbloader/FilesHelper.java b/src/main/java/nsusbloader/FilesHelper.java index 53771dc..739a375 100644 --- a/src/main/java/nsusbloader/FilesHelper.java +++ b/src/main/java/nsusbloader/FilesHelper.java @@ -28,8 +28,10 @@ public class FilesHelper { Path locationAsPath = Paths.get(location); if (Files.notExists(locationAsPath) || Files.isRegularFile(locationAsPath)) return System.getProperty("user.home"); + return location; + } + catch (Exception ignored){ + return System.getProperty("user.home"); } - catch (Exception ignored){} - return location; } }