mirror of
https://github.com/balena-io/balena-cli.git
synced 2025-01-31 08:25:36 +00:00
Fix callback not being called on success in os download command
This commit is contained in:
parent
9b0c08bd46
commit
9bb04f43a8
@ -74,9 +74,7 @@
|
||||
spinner = new visuals.widgets.Spinner('Downloading Device OS (size unknown)');
|
||||
return resin.models.os.download(osParams, options.output, function(error) {
|
||||
spinner.stop();
|
||||
if (error != null) {
|
||||
return callback(error);
|
||||
}
|
||||
return callback(error);
|
||||
}, function(state) {
|
||||
if (state != null) {
|
||||
return bar.update(state);
|
||||
|
@ -82,7 +82,7 @@ exports.download =
|
||||
|
||||
resin.models.os.download osParams, options.output, (error) ->
|
||||
spinner.stop()
|
||||
return callback(error) if error?
|
||||
return callback(error)
|
||||
, (state) ->
|
||||
if state?
|
||||
bar.update(state)
|
||||
|
Loading…
x
Reference in New Issue
Block a user