Skip to content
Snippets Groups Projects
Commit 9212f3ff authored by Fabian Seidl's avatar Fabian Seidl
Browse files

Resolve "Logging in while having an expired token shows an unnecessary error"


See merge request !359

Co-authored-by: default avatarFabian Seidl <fabian.seidl@h-da.de>
parent e3dc440b
No related branches found
No related tags found
2 merge requests!359Resolve "Logging in while having an expired token shows an unnecessary error",!333WIP: Develop
Pipeline #114771 passed
......@@ -59,10 +59,7 @@ var loginCmd = &cobra.Command{
// log out to remove active session in case an user is already logged in
if userToken != "" {
_, err := api.Logout(createContextWithAuthorization(), viper.GetString("controllerAPIEndpoint"), nbUserName)
if err != nil {
pterm.Error.Println("error logging out active user", err)
}
_, _ = api.Logout(createContextWithAuthorization(), viper.GetString("controllerAPIEndpoint"), nbUserName)
}
// TODO: maybe add credentials in context instead of context.TODO()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment