diff --git a/cmd/signaldctl/cmd/account/link/link-account.go b/cmd/signaldctl/cmd/account/link/link-account.go index 899815d..9cb3fa3 100644 --- a/cmd/signaldctl/cmd/account/link/link-account.go +++ b/cmd/signaldctl/cmd/account/link/link-account.go @@ -34,6 +34,7 @@ import ( var ( testing bool deviceName string + overwrite bool LinkAccountCmd = &cobra.Command{ Use: "link", @@ -80,6 +81,7 @@ var ( finishReq := v1.FinishLinkRequest{ DeviceName: deviceName, SessionId: response.SessionId, + Overwrite: overwrite, } _, err = finishReq.Submit(common.Signald) @@ -99,4 +101,5 @@ func init() { } LinkAccountCmd.Flags().BoolVarP(&testing, "testing", "t", false, "use the Signal testing server") LinkAccountCmd.Flags().StringVarP(&deviceName, "device-name", "n", name, "the name of this device. shown to other devices on the signal account") + LinkAccountCmd.Flags().BoolVar(&overwrite, "overwrite", false, "if an account with the same id already exists in signald's database, delete it before linking") }