don't show log window
[jSite2.git] / src / net / pterodactylus / util / fcp / PeerNote.java
index bac39bd..4efbc4f 100644 (file)
@@ -21,7 +21,7 @@ public class PeerNote extends BaseMessage {
         * @param receivedMessage
         *            The received message
         */
-       public PeerNote(FcpMessage receivedMessage) {
+       PeerNote(FcpMessage receivedMessage) {
                super(receivedMessage);
        }
 
@@ -37,12 +37,11 @@ public class PeerNote extends BaseMessage {
        /**
         * Returns the type of the peer note.
         * 
-        * @return The type of the peer note
-        * @throws NumberFormatException
-        *             if the field can not be parsed
+        * @return The type of the peer note, or <code>-1</code> if the type can
+        *         not be parsed
         */
-       public int getPeerNoteType() throws NumberFormatException {
-               return Integer.valueOf(getField("PeerNoteType"));
+       public int getPeerNoteType() {
+               return FcpUtils.safeParseInt(getField("PeerNoteType"));
        }
 
 }