Skip to content

Commit ceeaff7

Browse files
committed
fix(cubejs-cli): Correct missing auth error
1 parent 3ba2fbc commit ceeaff7

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

packages/cubejs-cli/deploy.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ const { logStage } = require('./utils');
99
const cloudReq = (options) => {
1010
const { url, auth, ...restOptions } = options;
1111
const authorization = auth || process.env.CUBE_CLOUD_DEPLOY_AUTH;
12+
if (!authorization) {
13+
throw new (`CUBE_CLOUD_DEPLOY_AUTH isn't set`);
14+
}
1215
const payload = jwt.decode(authorization);
1316
if (!payload.url || !payload.deploymentId) {
1417
throw new (`Malformed token: ${authorization}`);

0 commit comments

Comments
 (0)