mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2024-11-29 13:44:31 -05:00
14 lines
231 B
JavaScript
14 lines
231 B
JavaScript
|
'use strict'
|
||
|
|
||
|
const toobusy = require('toobusy-js')
|
||
|
|
||
|
const response = require('../../response')
|
||
|
|
||
|
module.exports = function (req, res, next) {
|
||
|
if (toobusy()) {
|
||
|
response.errorServiceUnavailable(res)
|
||
|
} else {
|
||
|
next()
|
||
|
}
|
||
|
}
|