mirror of
https://github.com/AsamK/signal-cli.git
synced 2026-05-07 11:30:15 +00:00
parent
d40f62ec21
commit
e6b33b8da7
@ -41,6 +41,9 @@ public class GetAttachmentCommand implements JsonRpcLocalCommand {
|
||||
) throws CommandException {
|
||||
|
||||
final var id = ns.getString("id");
|
||||
if (id == null) {
|
||||
throw new UserErrorException("Missing attachment id parameter");
|
||||
}
|
||||
|
||||
try (InputStream attachment = m.retrieveAttachment(id)) {
|
||||
final var bytes = attachment.readAllBytes();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user