mirror of
https://github.com/aljazceru/signal-cli.git
synced 2025-12-25 18:14:27 +01:00
Show better error message when using addDevice on a linked device
This commit is contained in:
@@ -185,6 +185,8 @@ public class DbusSignalImpl implements Signal {
|
||||
m.addDeviceLink(deviceLinkUrl);
|
||||
} catch (IOException | InvalidDeviceLinkException e) {
|
||||
throw new Error.Failure(e.getClass().getSimpleName() + " Add device link failed. " + e.getMessage());
|
||||
} catch (NotPrimaryDeviceException e) {
|
||||
throw new Error.Failure("This command doesn't work on linked devices.");
|
||||
} catch (URISyntaxException e) {
|
||||
throw new Error.InvalidUri(e.getClass().getSimpleName()
|
||||
+ " Device link uri has invalid format: "
|
||||
|
||||
Reference in New Issue
Block a user