2017-05-15 15:22:03 -05:00
|
|
|
import express = require('express')
|
|
|
|
|
2017-05-22 13:58:25 -05:00
|
|
|
import { CONFIG } from '../../initializers'
|
2017-05-15 15:22:03 -05:00
|
|
|
|
|
|
|
const configRouter = express.Router()
|
|
|
|
|
|
|
|
configRouter.get('/', getConfig)
|
|
|
|
|
|
|
|
// Get the client credentials for the PeerTube front end
|
|
|
|
function getConfig (req, res, next) {
|
|
|
|
res.json({
|
|
|
|
signup: {
|
|
|
|
enabled: CONFIG.SIGNUP.ENABLED
|
|
|
|
}
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
// ---------------------------------------------------------------------------
|
|
|
|
|
|
|
|
export {
|
|
|
|
configRouter
|
|
|
|
}
|