Skip to content

Commit

Permalink
refactor(server): remove PromiseContainer class
Browse files Browse the repository at this point in the history
BREAKING CHANGES: Removed PromiseContainer class as not used
  • Loading branch information
anthony-redFox committed Feb 28, 2020
1 parent a673aa8 commit 5ad56c6
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions lib/middleware/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,22 +99,7 @@ function setHeavyCacheHeaders (response) {
response.setHeader('Cache-Control', 'public, max-age=31536000')
}

class PromiseContainer {
constructor () {
this.promise = null
}

then (success, error) {
return this.promise.then(success, error)
}

set (newPromise) {
this.promise = newPromise
}
}

// PUBLIC API
exports.PromiseContainer = PromiseContainer
exports.createServeFile = createServeFile
exports.setNoCacheHeaders = setNoCacheHeaders
exports.setHeavyCacheHeaders = setHeavyCacheHeaders
Expand Down

0 comments on commit 5ad56c6

Please sign in to comment.