File tree Expand file tree Collapse file tree 4 files changed +7
-3
lines changed
Expand file tree Collapse file tree 4 files changed +7
-3
lines changed Original file line number Diff line number Diff line change 1818 "CLI_AUTH_LOGOUT_DESCRIPTION" : " User session logout" ,
1919 "CLI_AUTH_LOGOUT_FLAG_FORCE" : " Force logging out for skipping the confirmation" ,
2020 "CLI_AUTH_LOGOUT_ALREADY" : " You're already logged out" ,
21+ "CLI_AUTH_LOGOUT_CANCELLED" : " Log out cancelled" ,
2122 "CLI_AUTH_LOGOUT_NO_AUTHORIZATIONS" : " No authorizations found" ,
2223 "CLI_AUTH_LOGOUT_NO_AUTHORIZATIONS_USER" : " No authorizations found for current user" ,
2324 "CLI_AUTH_WHOAMI_LOGGED_IN_AS" : " You are currently logged in with email:" ,
Original file line number Diff line number Diff line change 11{
22 "name" : " @contentstack/cli-auth" ,
33 "description" : " Contentstack CLI plugin for authentication activities" ,
4- "version" : " 2.0.0-beta.6 " ,
4+ "version" : " 2.0.0-beta.7 " ,
55 "author" : " Contentstack" ,
66 "bugs" : " https://github.com/contentstack/cli/issues" ,
77 "scripts" : {
Original file line number Diff line number Diff line change @@ -84,7 +84,10 @@ export default class LogoutCommand extends BaseCommand<typeof LogoutCommand> {
8484 confirm,
8585 isAuthenticated : oauthHandler . isAuthenticated ( ) ,
8686 } ) ;
87- log . success ( messageHandler . parse ( 'CLI_AUTH_LOGOUT_ALREADY' ) , this . contextDetails ) ;
87+ const messageKey = confirm === false && oauthHandler . isAuthenticated ( )
88+ ? 'CLI_AUTH_LOGOUT_CANCELLED'
89+ : 'CLI_AUTH_LOGOUT_ALREADY' ;
90+ log . success ( messageHandler . parse ( messageKey ) , this . contextDetails ) ;
8891 }
8992 } catch ( error ) {
9093 log . debug ( 'Logout failed.' , { ...this . contextDetails , error : error . message } ) ;
Original file line number Diff line number Diff line change 2525 "@contentstack/cli-audit" : " ~2.0.0-beta.5" ,
2626 "@contentstack/cli-cm-export" : " ~2.0.0-beta.10" ,
2727 "@contentstack/cli-cm-import" : " ~2.0.0-beta.10" ,
28- "@contentstack/cli-auth" : " ~2.0.0-beta.6 " ,
28+ "@contentstack/cli-auth" : " ~2.0.0-beta.7 " ,
2929 "@contentstack/cli-bulk-operations" : " ^1.0.0-beta" ,
3030 "@contentstack/cli-cm-bootstrap" : " ~2.0.0-beta.10" ,
3131 "@contentstack/cli-cm-branches" : " ~2.0.0-beta.1" ,
You can’t perform that action at this time.
0 commit comments