X-Git-Url: https://git.nmode.ca/signal-cli/blobdiff_plain/7e7e4150e19a65c646bb3f4ec33b5ec87224f8cf..06e93b84da2718c31111e820cd35a3354f22bae2:/src/main/java/org/asamk/signal/dbus/DbusManagerImpl.java diff --git a/src/main/java/org/asamk/signal/dbus/DbusManagerImpl.java b/src/main/java/org/asamk/signal/dbus/DbusManagerImpl.java index adef6f96..5421d4ad 100644 --- a/src/main/java/org/asamk/signal/dbus/DbusManagerImpl.java +++ b/src/main/java/org/asamk/signal/dbus/DbusManagerImpl.java @@ -131,7 +131,7 @@ public class DbusManagerImpl implements Manager { emptyIfNull(about), emptyIfNull(aboutEmoji), avatar == null ? "" : avatar.map(File::getPath).orElse(""), - avatar != null && !avatar.isPresent()); + avatar != null && avatar.isEmpty()); } @Override @@ -383,12 +383,12 @@ public class DbusManagerImpl implements Manager { @Override public void deleteRecipient(final RecipientIdentifier.Single recipient) throws IOException { - throw new UnsupportedOperationException(); + signal.deleteRecipient(recipient.getIdentifier()); } @Override public void deleteContact(final RecipientIdentifier.Single recipient) throws IOException { - throw new UnsupportedOperationException(); + signal.deleteContact(recipient.getIdentifier()); } @Override @@ -786,9 +786,8 @@ public class DbusManagerImpl implements Manager { private void notifyMessageHandlers(final MessageEnvelope envelope) { synchronized (messageHandlers) { - Stream.concat(messageHandlers.stream(), weakHandlers.stream()).forEach(h -> { - h.handleMessage(envelope, null); - }); + Stream.concat(messageHandlers.stream(), weakHandlers.stream()) + .forEach(h -> h.handleMessage(envelope, null)); } }