mirror of
https://github.com/AsamK/signal-cli
synced 2025-08-29 18:40:39 +00:00
Don't abort on empty recipient unless there was also no group specified. (#176)
* Don't abort on empty recipient unless there was also no group specified. * Fixed potential error if user tries to send `endsession` to a group * Display error if trying to send `endsession` to a group * No need for this check since we're handling that condition above
This commit is contained in:
parent
5d843d82ef
commit
51c130b406
1 changed files with 1 additions and 1 deletions
|
@ -46,7 +46,7 @@ public class SendCommand implements DbusCommand {
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ns.getList("recipient") == null || ns.getList("recipient").size() == 0) {
|
if ((ns.getList("recipient") == null || ns.getList("recipient").size() == 0) && (ns.getBoolean("endsession") || ns.getString("group") == null)) {
|
||||||
System.err.println("No recipients given");
|
System.err.println("No recipients given");
|
||||||
System.err.println("Aborting sending.");
|
System.err.println("Aborting sending.");
|
||||||
return 1;
|
return 1;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue