Pass a ProgressState instance to bar.tick() directly

This commit is contained in:
Juan Cruz Viotti 2015-02-06 08:21:32 -04:00
parent 3005a91658
commit ca961d04c5

View File

@ -67,7 +67,7 @@ exports.download =
bar = new visuals.widgets.Progress('Downloading Device OS')
resin.models.os.download osParams, options.output, callback, (state) ->
console.log(bar.tick(state.percentage, state.eta))
console.log(bar.tick(state))
], (error) ->
return done(error) if error?
@ -132,7 +132,7 @@ exports.install =
bar = new visuals.widgets.Progress('Writing Device OS')
progress.on 'progress', (status) ->
console.log(bar.tick(status.percentage, status.eta))
console.log(bar.tick(status))
imageFileStream = fs.createReadStream(params.image).pipe(progress)