From: David ‘Bombe’ Roden Date: Thu, 11 Nov 2010 05:33:25 +0000 (+0100) Subject: Rename variable and don’t forget to increment counter. X-Git-Tag: 0.2.1~8 X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=4642e7fb8a7aa173915069d9c66395d5e898b3c5;p=Sone.git Rename variable and don’t forget to increment counter. --- diff --git a/src/main/java/net/pterodactylus/sone/core/Core.java b/src/main/java/net/pterodactylus/sone/core/Core.java index 450e996..616dd04 100644 --- a/src/main/java/net/pterodactylus/sone/core/Core.java +++ b/src/main/java/net/pterodactylus/sone/core/Core.java @@ -857,8 +857,8 @@ public class Core implements IdentityListener { /* save friends. */ int friendCounter = 0; - for (String friend : sone.getFriends()) { - configuration.getStringValue(sonePrefix + "/Friends/" + friendCounter + "/ID").setValue(friend); + for (String friendId : sone.getFriends()) { + configuration.getStringValue(sonePrefix + "/Friends/" + friendCounter++ + "/ID").setValue(friendId); } configuration.getStringValue(sonePrefix + "/Friends/" + friendCounter + "/ID").setValue(null);