Iterate over the current versions of the Sones.
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Thu, 27 Feb 2014 07:38:13 +0000 (08:38 +0100)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Thu, 27 Feb 2014 07:38:13 +0000 (08:38 +0100)
The keys used in the soneInserters map are Sones fresh from the startup,
most of them shouldn’t even have profiles.

src/main/java/net/pterodactylus/sone/core/Core.java

index 7e93410..ecb5857 100644 (file)
@@ -1763,7 +1763,7 @@ public class Core extends AbstractService implements SoneProvider, PostProvider,
                synchronized (sones) {
                        for (Entry<Sone, SoneInserter> soneInserter : soneInserters.entrySet()) {
                                soneInserter.getValue().stop();
-                               saveSone(soneInserter.getKey());
+                               saveSone(getLocalSone(soneInserter.getKey().getId(), false));
                        }
                }
                saveConfiguration();