diff options
Diffstat (limited to 'commands/user_adopt.go')
-rw-r--r-- | commands/user_adopt.go | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/commands/user_adopt.go b/commands/user_adopt.go index a7de54d9..7054f1f7 100644 --- a/commands/user_adopt.go +++ b/commands/user_adopt.go @@ -4,11 +4,10 @@ import ( "fmt" "os" - "github.com/MichaelMure/git-bug/bridge/core/auth" + "github.com/spf13/cobra" + "github.com/MichaelMure/git-bug/cache" - "github.com/MichaelMure/git-bug/identity" "github.com/MichaelMure/git-bug/util/interrupt" - "github.com/spf13/cobra" ) func runUserAdopt(cmd *cobra.Command, args []string) error { @@ -26,16 +25,6 @@ func runUserAdopt(cmd *cobra.Command, args []string) error { return err } - _, err = backend.GetUserIdentity() - if err == identity.ErrNoIdentitySet { - err = auth.ReplaceDefaultUser(repo, i.Id()) - if err != nil { - return err - } - } else if err != nil { - return err - } - err = backend.SetUserIdentity(i) if err != nil { return err |