diff --git a/src/main/java/com/sparrowwallet/drongo/pgp/PGPUtils.java b/src/main/java/com/sparrowwallet/drongo/pgp/PGPUtils.java index 91321f6..2b218b2 100644 --- a/src/main/java/com/sparrowwallet/drongo/pgp/PGPUtils.java +++ b/src/main/java/com/sparrowwallet/drongo/pgp/PGPUtils.java @@ -172,7 +172,10 @@ public class PGPUtils { } if(isWindows()) { - return new File(System.getenv("APPDATA"), "gnupg"); + File winHome = new File(System.getenv("APPDATA"), "gnupg"); + if(winHome.exists()) { + return winHome; + } } return new File(System.getProperty("user.home"), ".gnupg");