File tree Expand file tree Collapse file tree 1 file changed +10
-10
lines changed
packages/hadron-build/commands Expand file tree Collapse file tree 1 file changed +10
-10
lines changed Original file line number Diff line number Diff line change @@ -43,16 +43,7 @@ async function maybePublishGitHubRelease(target) {
4343 // already published releases.
4444 await repo . updateDraftRelease ( release ) ;
4545
46- const assets = target . assets . filter ( function ( asset ) {
47- // eslint-disable-next-line no-sync
48- var exists = fs . existsSync ( asset . path ) ;
49- if ( ! exists ) {
50- cli . warn ( `Excluding ${ asset . path } from upload because it does not exist.` ) ;
51- }
52- return exists ;
53- } ) ;
54-
55- const uploads = assets . map (
46+ const uploads = target . assets . map (
5647 async function ( asset ) {
5748 cli . info ( `${ asset . name } : upload to Github release ${ releaseTag } started (path: ${ asset . path } ).` ) ;
5849 await repo . uploadReleaseAsset ( releaseTag , {
@@ -92,6 +83,15 @@ exports.handler = function(argv) {
9283 return ;
9384 }
9485
86+ target . assets = target . assets . filter ( function ( asset ) {
87+ // eslint-disable-next-line no-sync
88+ var exists = fs . existsSync ( asset . path ) ;
89+ if ( ! exists ) {
90+ cli . warn ( `Excluding ${ asset . path } from upload because it does not exist.` ) ;
91+ }
92+ return exists ;
93+ } ) ;
94+
9595 maybePublishGitHubRelease ( target )
9696 . then ( ( ) => downloadCenter . maybeUpload ( target ) )
9797 . catch ( abortIfError ) ;
You can’t perform that action at this time.
0 commit comments