mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-24 06:35:49 +03:00
16 lines
463 B
JavaScript
16 lines
463 B
JavaScript
const configUrlHelpers = require('./lib/config-url-helpers');
|
|
|
|
/**
|
|
* @typedef {Object} BoundHelpers
|
|
* @property {configUrlHelpers.getSubdirFn} getSubdir
|
|
* @property {configUrlHelpers.getSiteUrlFn} getSiteUrl
|
|
* @property {configUrlHelpers.getAdminUrlFn} getAdminUrl
|
|
*
|
|
* @param {*} nconf
|
|
*/
|
|
module.exports.bindAll = (nconf) => {
|
|
Object.keys(configUrlHelpers).forEach((helper) => {
|
|
nconf[helper] = configUrlHelpers[helper].bind(nconf);
|
|
});
|
|
};
|