File tree Expand file tree Collapse file tree 2 files changed +4
-1
lines changed Expand file tree Collapse file tree 2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ const schemaBrowser = require("../shared/schema-browser");
2
2
const inputUtil = require ( "../shared/input-util" ) ;
3
3
const templateParser = require ( "../shared/template-parser" ) ;
4
4
const SchemasClient = require ( "aws-sdk/clients/schemas" ) ;
5
- const schemas = new SchemasClient ( ) ;
6
5
const jsf = require ( "json-schema-faker" ) ;
7
6
const jp = require ( "jsonpath" ) ;
8
7
const toJsonSchema = require ( "to-json-schema" ) ;
@@ -20,6 +19,7 @@ require("./languages/python");
20
19
require ( "./languages/java" ) ;
21
20
require ( "./languages/swift" ) ;
22
21
async function loadFromRegistry ( cmd ) {
22
+ const schemas = new SchemasClient ( ) ;
23
23
const schemaLocation = await schemaBrowser . getSchemaName ( schemas ) ;
24
24
const schema = await schemas
25
25
. exportSchema ( {
@@ -32,6 +32,8 @@ async function loadFromRegistry(cmd) {
32
32
}
33
33
34
34
async function loadFromTemplate ( cmd ) {
35
+ const schemas = new SchemasClient ( ) ;
36
+
35
37
if ( ! cmd . registryName ) {
36
38
cmd . registryName = ( await inputUtil . getRegistry ( schemas ) ) . id ;
37
39
}
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ require("@mhlabs/aws-sdk-sso");
4
4
function initAuth ( cmd ) {
5
5
6
6
const credentials = new AWS . SharedIniFileCredentials ( { profile : cmd . profile } ) ;
7
+ console . log ( credentials ) ;
7
8
if ( credentials . accessKeyId ) {
8
9
AWS . config . credentials = credentials ;
9
10
} else {
You can’t perform that action at this time.
0 commit comments