Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Toolchain
sgc
Commits
ee7f7a7f
Commit
ee7f7a7f
authored
Aug 31, 2018
by
Philipp Nowinski
Browse files
[BUGFIX] fix early exit
parent
67d6ae2a
Changes
1
Hide whitespace changes
Inline
Side-by-side
core/tasks/js.js
View file @
ee7f7a7f
...
...
@@ -146,13 +146,18 @@ module.exports = class Js extends Task {
));
}
bundler
.
pipe
(
fs
.
createWriteStream
(
_output
));
// create the stream for writing the outFile
let
outFile
=
fs
.
createWriteStream
(
_output
,
'
utf-8
'
);
bundler
.
on
(
'
end
'
,
()
=>
{
// wait for the stream to finish writing before calling success
outFile
.
on
(
'
finish
'
,
()
=>
{
browserSync
.
reload
(
'
*.js
'
);
this
.
_logger
.
success
(
`Written
${
chalk
.
white
(
path
.
basename
(
_output
))}
`
);
resolve
();
});
// announce the write stream as a build step
bundler
.
pipe
(
outFile
);
}
catch
(
_error
)
{
this
.
_logger
.
error
(
_error
.
stack
);
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment