- this.segmentsSha256Queue = queue<SegmentSha256QueueParam, Error>((options, cb) => {
- const promise = options.operation === 'update'
- ? this.addSegmentSha(options)
- : Promise.resolve(this.removeSegmentSha(options))
-
- promise.then(() => cb())
- .catch(err => {
- logger.error('Cannot update/remove sha segment %s.', options.segmentPath, { err })
- cb()
- })
- })
-