From 2080c2dfdd65640f8e7b177da511bc3312a20ec2 Mon Sep 17 00:00:00 2001 From: Arne Babenhauserheide Date: Sun, 1 Dec 2024 09:35:04 +0100 Subject: [PATCH] Add braces for if/else --- src/freenet/node/PeerManager.java | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/freenet/node/PeerManager.java b/src/freenet/node/PeerManager.java index 8c9bf68e1b..42d0e7a948 100644 --- a/src/freenet/node/PeerManager.java +++ b/src/freenet/node/PeerManager.java @@ -209,19 +209,21 @@ void tryReadPeers(String filename, NodeCrypto crypto, OpennetManager opennet, bo if(peersFile.exists()) if(readPeers(peersFile, crypto, opennet, oldOpennetPeers)) { String msg; - if(oldOpennetPeers) + if(oldOpennetPeers) { msg = "Read " + opennet.countOldOpennetPeers() + " old-opennet-peers from " + peersFile; - else if(isOpennet) + } else if(isOpennet) { msg = "Read " + getOpennetPeers().length + " opennet peers from " + peersFile; - else + } else { msg = "Read " + getDarknetPeers().length + " darknet peers from " + peersFile; + } Logger.normal(this, msg); System.out.println(msg); return; } } - if(!isOpennet) + if(!isOpennet) { System.out.println("No darknet peers file found."); + } // The other cases are less important. }