From 6754eed9b418ccf9b41536e750565daa12662d1d Mon Sep 17 00:00:00 2001 From: Egil Moeller Date: Sat, 25 Feb 2012 16:53:15 +0100 Subject: [PATCH] Renamed functions to match hook names --- node/minified.js | 2 +- node/padreadonly.js | 2 +- node/padurlsanitize.js | 2 +- node/specialpages.js | 2 +- node/static.js | 2 +- pluginomatic.json | 10 +++++----- 6 files changed, 10 insertions(+), 10 deletions(-) diff --git a/node/minified.js b/node/minified.js index 57978a1e4..f0f050a71 100644 --- a/node/minified.js +++ b/node/minified.js @@ -1,6 +1,6 @@ var minify = require('./utils/Minify'); -exports.expressServer = function (hook_name, args, cb) { +exports.expressCreateServer = function (hook_name, args, cb) { //serve minified files args.app.get('/minified/:filename', minify.minifyJS); } diff --git a/node/padreadonly.js b/node/padreadonly.js index 50a5e06ee..0121e7eb8 100644 --- a/node/padreadonly.js +++ b/node/padreadonly.js @@ -4,7 +4,7 @@ var hasPadAccess = require("./padaccess"); var exporthtml = require("./utils/ExportHtml"); var ERR = require("async-stacktrace"); -exports.expressServer = function (hook_name, args, cb) { +exports.expressCreateServer = function (hook_name, args, cb) { //serve read only pad args.app.get('/ro/:id', function(req, res) { diff --git a/node/padurlsanitize.js b/node/padurlsanitize.js index b3885578e..6fdd5f79a 100644 --- a/node/padurlsanitize.js +++ b/node/padurlsanitize.js @@ -1,6 +1,6 @@ var padManager = require('./db/PadManager'); -exports.expressServer = function (hook_name, args, cb) { +exports.expressCreateServer = function (hook_name, args, cb) { //redirects browser to the pad's sanitized url if needed. otherwise, renders the html args.app.param('pad', function (req, res, next, padId) { //ensure the padname is valid and the url doesn't end with a / diff --git a/node/specialpages.js b/node/specialpages.js index 9a4bcb333..02509767d 100644 --- a/node/specialpages.js +++ b/node/specialpages.js @@ -1,6 +1,6 @@ var path = require('path'); -exports.expressServer = function (hook_name, args, cb) { +exports.expressCreateServer = function (hook_name, args, cb) { //serve index.html under / args.app.get('/', function(req, res) diff --git a/node/static.js b/node/static.js index 71f40b45d..a81227a48 100644 --- a/node/static.js +++ b/node/static.js @@ -1,7 +1,7 @@ var path = require('path'); var minify = require('./utils/Minify'); -exports.expressServer = function (hook_name, args, cb) { +exports.expressCreateServer = function (hook_name, args, cb) { //serve static files args.app.get('/static/js/require-kernel.js', function (req, res, next) { res.header("Content-Type","application/javascript; charset: utf-8"); diff --git a/pluginomatic.json b/pluginomatic.json index 04b61c313..e37d43a48 100644 --- a/pluginomatic.json +++ b/pluginomatic.json @@ -1,10 +1,10 @@ { "parts": [ - { "name": "static", "hooks": { "expressCreateServer": "../static:expressServer" } }, - { "name": "specialpages", "hooks": { "expressCreateServer": "../specialpages:expressServer" } }, - { "name": "padurlsanitize", "hooks": { "expressCreateServer": "../padurlsanitize:expressServer" } }, - { "name": "minified", "hooks": { "expressCreateServer": "../minified:expressServer" } }, - { "name": "padreadonly", "hooks": { "expressCreateServer": "../padreadonly:expressServer" } }, + { "name": "static", "hooks": { "expressCreateServer": "../static:expressCreateServer" } }, + { "name": "specialpages", "hooks": { "expressCreateServer": "../specialpages:expressCreateServer" } }, + { "name": "padurlsanitize", "hooks": { "expressCreateServer": "../padurlsanitize:expressCreateServer" } }, + { "name": "minified", "hooks": { "expressCreateServer": "../minified:expressCreateServer" } }, + { "name": "padreadonly", "hooks": { "expressCreateServer": "../padreadonly:expressCreateServer" } }, { "name": "webaccess", "hooks": { "expressConfigure": "../webaccess:expressConfigure" } }, { "name": "apicalls", "hooks": { "expressCreateServer": "../apicalls:expressCreateServer" } }, { "name": "importexport", "hooks": { "expressCreateServer": "../importexport:expressCreateServer" } },