mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-08-18 16:02:10 +00:00
fix(cli): fix wmill user create-token with email and password
This commit is contained in:
+3
-1
@@ -109,6 +109,8 @@ async function remove(opts: GlobalOptions, email: string) {
|
||||
async function createToken(
|
||||
opts: GlobalOptions & { email: string; password: string }
|
||||
) {
|
||||
await requireLogin(opts);
|
||||
|
||||
if (opts.email && opts.password) {
|
||||
log.info(
|
||||
"Token: " +
|
||||
@@ -119,9 +121,9 @@ async function createToken(
|
||||
},
|
||||
}))
|
||||
);
|
||||
return;
|
||||
}
|
||||
|
||||
await requireLogin(opts);
|
||||
log.info("Token: " + (await wmill.createToken({ requestBody: {} })));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user