mirror of
https://github.com/balena-io/balena-cli.git
synced 2025-04-11 21:29:56 +00:00
Fix #73
This commit is contained in:
parent
0bb0e6ea4b
commit
e2125b8ce9
@ -140,7 +140,12 @@
|
||||
if (username == null) {
|
||||
throw new Error('Username not found');
|
||||
}
|
||||
return console.log(username);
|
||||
return resin.auth.getEmail().then(function(email) {
|
||||
if (email == null) {
|
||||
throw new Error('Email not found');
|
||||
}
|
||||
return console.log(("Username: " + username) + '\n' + ("Email: " + email));
|
||||
});
|
||||
}).nodeify(done);
|
||||
}
|
||||
};
|
||||
|
@ -177,5 +177,8 @@ exports.whoami =
|
||||
resin.auth.whoami().then (username) ->
|
||||
if not username?
|
||||
throw new Error('Username not found')
|
||||
console.log(username)
|
||||
resin.auth.getEmail().then (email) ->
|
||||
if not email?
|
||||
throw new Error('Email not found')
|
||||
console.log "Username: #{username}" + '\n' + "Email: #{email}"
|
||||
.nodeify(done)
|
||||
|
Loading…
x
Reference in New Issue
Block a user