mirror of
https://github.com/AsamK/signal-cli
synced 2025-08-29 18:40:39 +00:00
Add CommandException to abstract cli return codes for errors
This commit is contained in:
parent
c6395b9f35
commit
221d937eec
47 changed files with 538 additions and 572 deletions
|
@ -8,7 +8,6 @@ import org.slf4j.LoggerFactory;
|
|||
import org.whispersystems.signalservice.api.messages.SignalServiceContent;
|
||||
import org.whispersystems.signalservice.api.messages.SignalServiceEnvelope;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.HashMap;
|
||||
|
||||
public class JsonReceiveMessageHandler implements Manager.ReceiveMessageHandler {
|
||||
|
@ -32,10 +31,7 @@ public class JsonReceiveMessageHandler implements Manager.ReceiveMessageHandler
|
|||
if (envelope != null) {
|
||||
object.put("envelope", new JsonMessageEnvelope(envelope, content, m));
|
||||
}
|
||||
try {
|
||||
jsonWriter.write(object);
|
||||
} catch (IOException e) {
|
||||
logger.error("Failed to write json object: {}", e.getMessage());
|
||||
}
|
||||
|
||||
jsonWriter.write(object);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue