X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Fcore%2FCore.java;h=0571e0d2adb710eb01182a9e4d590df953e02890;hp=4d39c101e9d6a58326d83c5e8283c320c2a3d493;hb=69870060d45d5cdca064e67779dfc5619001ae42;hpb=3c8d2fc3f4b11f8ccd7fcce6339ba1a34c055ac5 diff --git a/src/main/java/net/pterodactylus/sone/core/Core.java b/src/main/java/net/pterodactylus/sone/core/Core.java index 4d39c10..0571e0d 100644 --- a/src/main/java/net/pterodactylus/sone/core/Core.java +++ b/src/main/java/net/pterodactylus/sone/core/Core.java @@ -347,11 +347,10 @@ public class Core extends AbstractService implements SoneProvider, PostProvider, } /** - * Returns all Sones, remote and local. - * - * @return All Sones + * {@inheritDocs} */ - public Set getSones() { + @Override + public Collection getSones() { synchronized (sones) { return Collections.unmodifiableCollection(sones.values()); } @@ -374,10 +373,9 @@ public class Core extends AbstractService implements SoneProvider, PostProvider, } /** - * Returns all local Sones. - * - * @return All local Sones + * {@inheritDocs} */ + @Override public Collection getLocalSones() { synchronized (sones) { return Collections2.filter(sones.values(), new Predicate() { @@ -416,10 +414,9 @@ public class Core extends AbstractService implements SoneProvider, PostProvider, } /** - * Returns all remote Sones. - * - * @return All remote Sones + * {@inheritDocs} */ + @Override public Collection getRemoteSones() { synchronized (sones) { return Collections2.filter(sones.values(), new Predicate() { @@ -1094,6 +1091,7 @@ public class Core extends AbstractService implements SoneProvider, PostProvider, } } synchronized (sones) { + sone.setOptions(storedSone.get().getOptions()); sones.put(sone.getId(), sone); } }