Use SignalServiceAddress in more places

This commit is contained in:
AsamK 2020-03-23 17:09:56 +01:00
parent 8a44b37774
commit e2b7bda65b
11 changed files with 124 additions and 114 deletions

View file

@ -13,6 +13,7 @@ import org.asamk.signal.util.IOUtils;
import org.asamk.signal.util.Util;
import org.freedesktop.dbus.exceptions.DBusExecutionException;
import org.whispersystems.signalservice.api.push.exceptions.EncapsulatedExceptions;
import org.whispersystems.signalservice.api.util.InvalidNumberException;
import java.io.IOException;
import java.nio.charset.Charset;
@ -25,6 +26,7 @@ import static org.asamk.signal.util.ErrorUtils.handleEncapsulatedExceptions;
import static org.asamk.signal.util.ErrorUtils.handleGroupIdFormatException;
import static org.asamk.signal.util.ErrorUtils.handleGroupNotFoundException;
import static org.asamk.signal.util.ErrorUtils.handleIOException;
import static org.asamk.signal.util.ErrorUtils.handleInvalidNumberException;
import static org.asamk.signal.util.ErrorUtils.handleNotAGroupMemberException;
public class SendCommand implements DbusCommand {
@ -75,6 +77,9 @@ public class SendCommand implements DbusCommand {
} catch (DBusExecutionException e) {
handleDBusExecutionException(e);
return 1;
} catch (InvalidNumberException e) {
handleInvalidNumberException(e);
return 1;
}
}
@ -126,6 +131,9 @@ public class SendCommand implements DbusCommand {
} catch (GroupIdFormatException e) {
handleGroupIdFormatException(e);
return 1;
} catch (InvalidNumberException e) {
handleInvalidNumberException(e);
return 1;
}
}
}