Skip to content

Commit 001efa9

Browse files
committed
fixed await with Compliant Solution
1 parent 11b8308 commit 001efa9

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

bin/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ async function run(argv:AnyObject) {
3838

3939

4040
if (AppType !== "Customizable") {
41-
stackname[`stackName${i}`]=util.makeid(2)
41+
stackname[`stackName${i}`]=await util.makeid()
4242
let stack_name = stackname
4343
let stackName:string = stack_name[`stackName${i}`];
4444
if (AppType === "CRUD") {

cli-main/util.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -518,7 +518,7 @@ export let langValue=async function () {
518518

519519
}
520520

521-
export let samValidate=function(){
521+
export let samValidate=async function(){
522522
try {
523523
let files:AnyArray=fs.readdirSync(exec("pwd").toString().replace("\n",""))
524524
let yamlfiles:AnyArray=[]
@@ -541,7 +541,7 @@ export let samValidate=function(){
541541
}
542542

543543
}
544-
export let makeid =function (length) {
544+
export let makeid =async function () {
545545
const crypto = require('crypto');
546546
return (crypto.randomBytes(1).toString("base64url").replace(/\d/g, 'd')).toLowerCase();
547547
}

0 commit comments

Comments
 (0)