From e6e035ccac6e9c4cc36009240117c09dde7097b7 Mon Sep 17 00:00:00 2001 From: Ara Yeressian Date: Fri, 26 Jun 2020 18:18:22 +0400 Subject: [PATCH] testing not deployment --- dist/index.js | 5 +++++ src/uploader.ts | 6 +++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/dist/index.js b/dist/index.js index c3657fd..408bf5c 100644 --- a/dist/index.js +++ b/dist/index.js @@ -9750,7 +9750,12 @@ function uploadFile(entry, storageName, accessKey) { if (response.status === 200) { core_1.info(`Successfull deployment of ${entry.path}`); } + else { + return response; + } return response; + }).catch(errorObj => { + core_1.error(errorObj); }); } async function run(path, storageName, accessKey) { diff --git a/src/uploader.ts b/src/uploader.ts index 1a8f65d..8e5b1f9 100644 --- a/src/uploader.ts +++ b/src/uploader.ts @@ -1,7 +1,7 @@ import fs from 'fs'; import fetch from 'node-fetch'; import readdirp from 'readdirp'; -import { info } from '@actions/core'; +import { info, error } from '@actions/core'; function uploadFile(entry: readdirp.EntryInfo, storageName: string, accessKey: string) { const stats = fs.statSync(entry.fullPath); @@ -19,8 +19,12 @@ function uploadFile(entry: readdirp.EntryInfo, storageName: string, accessKey: s }).then(response => { if (response.status === 200) { info(`Successfull deployment of ${entry.path}`); + } else { + return response; } return response; + }).catch(errorObj => { + error(errorObj); }); }