Wrap services.getAll in a bluebird promise

Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
This commit is contained in:
Cameron Diver 2019-01-31 10:09:25 +00:00
parent e2c159f009
commit ef7d993db6
No known key found for this signature in database
GPG Key ID: 49690ED87032539F

View File

@ -882,7 +882,7 @@ module.exports = class ApplicationManager extends EventEmitter
return _.uniqWith(nextSteps, _.isEqual)
stopAll: ({ force = false, skipLock = false } = {}) =>
@services.getAll()
Promise.resolve(@services.getAll())
.map (service) =>
@_lockingIfNecessary service.appId, { force, skipLock }, =>
@services.kill(service, { removeContainer: false, wait: true })