fix formatting

Signed-off-by: Eli Uriegas <eliuriegas@fb.com>
This commit is contained in:
Eli Uriegas 2021-05-18 11:15:30 -07:00
parent 91f3fe2635
commit ed1916672d
No known key found for this signature in database
GPG key ID: EE2C3B4893010973
2 changed files with 14 additions and 14 deletions

2
dist/index.js vendored
View file

@ -31173,7 +31173,7 @@ function run() {
const name = core.getInput(constants_1.Inputs.Name, { required: false }); const name = core.getInput(constants_1.Inputs.Name, { required: false });
const chosenPath = core.getInput(constants_1.Inputs.Path, { required: false }); const chosenPath = core.getInput(constants_1.Inputs.Path, { required: false });
const s3Bucket = core.getInput(constants_1.Inputs.S3Bucket, { required: false }); const s3Bucket = core.getInput(constants_1.Inputs.S3Bucket, { required: false });
let resolvedPath = ""; let resolvedPath = '';
// resolve tilde expansions, path.replace only replaces the first occurrence of a pattern // resolve tilde expansions, path.replace only replaces the first occurrence of a pattern
if (chosenPath.startsWith(`~`)) { if (chosenPath.startsWith(`~`)) {
path_1.default.resolve(); path_1.default.resolve();

View file

@ -13,7 +13,7 @@ async function run(): Promise<void> {
const chosenPath = core.getInput(Inputs.Path, {required: false}) const chosenPath = core.getInput(Inputs.Path, {required: false})
const s3Bucket = core.getInput(Inputs.S3Bucket, {required: false}) const s3Bucket = core.getInput(Inputs.S3Bucket, {required: false})
let resolvedPath = ""; let resolvedPath = ''
// resolve tilde expansions, path.replace only replaces the first occurrence of a pattern // resolve tilde expansions, path.replace only replaces the first occurrence of a pattern
if (chosenPath.startsWith(`~`)) { if (chosenPath.startsWith(`~`)) {
path.resolve() path.resolve()
@ -34,10 +34,9 @@ async function run(): Promise<void> {
continue continue
} }
core.info(`Grabbing ${fileObject.Key}`) core.info(`Grabbing ${fileObject.Key}`)
s3.getObject({Bucket: s3Bucket, Key: fileObject.Key}, function ( s3.getObject(
err, {Bucket: s3Bucket, Key: fileObject.Key},
fileContents function (err, fileContents) {
) {
if (err) { if (err) {
core.error(err) core.error(err)
throw err throw err
@ -46,7 +45,8 @@ async function run(): Promise<void> {
path.resolve(resolvedPath, fileObject.Key as string), path.resolve(resolvedPath, fileObject.Key as string),
fileContents.Body?.toString() fileContents.Body?.toString()
) )
}) }
)
} }
}) })
// output the directory that the artifact(s) was/were downloaded to // output the directory that the artifact(s) was/were downloaded to