Log if an own identity is missing.
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Fri, 16 Sep 2011 15:45:10 +0000 (17:45 +0200)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Fri, 16 Sep 2011 15:45:10 +0000 (17:45 +0200)
src/main/java/net/pterodactylus/wotns/main/Resolver.java

index 0d94ce2..63123b2 100644 (file)
@@ -23,7 +23,10 @@ import java.util.Collections;
 import java.util.Comparator;
 import java.util.List;
 import java.util.Set;
+import java.util.logging.Level;
+import java.util.logging.Logger;
 
+import net.pterodactylus.util.logging.Logging;
 import net.pterodactylus.util.object.Default;
 import net.pterodactylus.wotns.freenet.wot.Identity;
 import net.pterodactylus.wotns.freenet.wot.IdentityManager;
@@ -38,6 +41,8 @@ import freenet.keys.FreenetURI;
  */
 public class Resolver {
 
+       private static final Logger logger = Logging.getLogger(Resolver.class);
+
        private final IdentityManager identityManager;
 
        private String ownIdentityId;
@@ -97,6 +102,7 @@ public class Resolver {
                                ownIdentity = null;
                        }
                } else {
+                       logger.log(Level.SEVERE, "Can not resolve “" + shortName + "” without a Web of Trust Identity!");
                        ownIdentity = null;
                }
                if (ownIdentity == null) {