Skip to content

Commit

Permalink
fix: address review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
AjazSumaiya committed Nov 22, 2024
1 parent 483731e commit 59e3708
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 16 deletions.
2 changes: 1 addition & 1 deletion src/commands/api-mesh/__tests__/delete.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ describe('delete command tests', () => {
`);
});

test('should delete mesh if correct args are provided', async () => {
test('should delete mesh if correct args are provided', async () => {
const runResult = await DeleteCommand.run();

expect(initRequestId).toHaveBeenCalled();
Expand Down
16 changes: 1 addition & 15 deletions src/lib/devConsole.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,21 +90,7 @@ const describeMesh = async (organizationId, projectId, workspaceId, workspaceNam

logger.info('Response from getMeshId %s', meshId);

if (meshId) {
const credential = await getApiKeyCredential(organizationId, projectId, workspaceId);

if (credential) {
return { meshId, apiKey: null };
} else {
logger.error('credentials not found on workspace');

return { meshId, apiKey: null };
}
} else {
logger.error(`Unable to retrieve meshId.`);

throw new Error(`Unable to retrieve meshId.`);
}
return { meshId, apiKey: null };
} catch (error) {
logger.error(error);

Expand Down

0 comments on commit 59e3708

Please sign in to comment.