Fix an issue with instance social
This commit is contained in:
parent
426658695e
commit
62f84f5637
|
@ -78,11 +78,7 @@ public class InstanceSocialVM extends AndroidViewModel {
|
||||||
InstanceSocial filtered = new InstanceSocial();
|
InstanceSocial filtered = new InstanceSocial();
|
||||||
filtered.instances = new ArrayList<>();
|
filtered.instances = new ArrayList<>();
|
||||||
if (instanceSocial != null && instanceSocial.instances != null) {
|
if (instanceSocial != null && instanceSocial.instances != null) {
|
||||||
for (InstanceSocial.Instance instance : instanceSocial.instances) {
|
filtered.instances.addAll(instanceSocial.instances);
|
||||||
if (instance.up) {
|
|
||||||
filtered.instances.add(instance);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
Runnable myRunnable = () -> instanceSocialMutableLiveData.setValue(filtered);
|
Runnable myRunnable = () -> instanceSocialMutableLiveData.setValue(filtered);
|
||||||
mainHandler.post(myRunnable);
|
mainHandler.post(myRunnable);
|
||||||
|
|
Loading…
Reference in New Issue