mirror of
https://github.com/strapi/strapi.git
synced 2025-07-19 07:02:26 +00:00
30 lines
435 B
JavaScript
30 lines
435 B
JavaScript
'use strict';
|
|
|
|
/**
|
|
* Module dependencies
|
|
*/
|
|
|
|
// Public node modules.
|
|
const _ = require('lodash');
|
|
|
|
// Local node modules.
|
|
const routeService = require('./helpers');
|
|
|
|
/**
|
|
* Returns the config of the application used
|
|
* by the admin panel
|
|
*/
|
|
|
|
module.exports = function * () {
|
|
let routes;
|
|
|
|
try {
|
|
routes = yield routeService.find();
|
|
|
|
this.body = routes;
|
|
} catch (err) {
|
|
this.status = 500;
|
|
this.body = err;
|
|
}
|
|
};
|