I2P Address: [http://git.idk.i2p]

Skip to content
Snippets Groups Projects
Commit 02e7a19f authored by zzz's avatar zzz
Browse files

* i2psnark: Change displayed peer idents to match that shown by bytemonsoon

parent c6a697df
No related branches found
No related tags found
No related merge requests found
...@@ -167,7 +167,9 @@ public class PeerID implements Comparable ...@@ -167,7 +167,9 @@ public class PeerID implements Comparable
} }
/** /**
* Returns the String "id@address" where id is the base64 encoded id. * Returns the String "id@address" where id is the base64 encoded id
* and address is the base64 dest (was the base64 hash of the dest) which
* should match what the bytemonsoon tracker reports on its web pages.
*/ */
public String toString() public String toString()
{ {
...@@ -178,7 +180,7 @@ public class PeerID implements Comparable ...@@ -178,7 +180,7 @@ public class PeerID implements Comparable
break; break;
} }
} }
return Base64.encode(id, nonZero, id.length-nonZero).substring(0,4) + "@" + address.calculateHash().toBase64().substring(0,6); return Base64.encode(id, nonZero, id.length-nonZero).substring(0,4) + "@" + address.toBase64().substring(0,6);
} }
/** /**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment