Skip to content

Commit

Permalink
Add braces for if/else
Browse files Browse the repository at this point in the history
  • Loading branch information
ArneBab committed Dec 1, 2024
1 parent b5e9274 commit 2080c2d
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/freenet/node/PeerManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -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.
}

Expand Down

0 comments on commit 2080c2d

Please sign in to comment.