authed.js 623 Bytes
var express = require('express');

exports = module.exports = function (IoC, policies, settings) {
	var app = this;
	var router = express.Router();
	var controller = IoC.create('controllers/authed');

	router.get(
		'/*',
		controller.get
	);

	router.post(
		'/*',
		controller.post
	);

	router.put(
		'/*',
		controller.put
	);

	router.patch(
		'/*',
		controller.patch
	);

	router.head(
		'/*',
		controller.head
	);

	router.delete(
		'/*',
		controller.delete
	);

	app.use(settings.prefix + 'auth_api', router);
};

exports['@require'] = ['$container', 'policies', 'igloo/settings'];
exports['@singleton'] = true;