1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2025-09-12 15:56:05 +00:00

Be consistent about lower case parameter names

This commit is contained in:
Jermolene
2018-06-26 15:39:43 +01:00
parent 43b64fc2ca
commit 501d0a8edc
4 changed files with 12 additions and 12 deletions

View File

@@ -36,13 +36,13 @@ Command.prototype.execute = function() {
variables: { variables: {
port: this.params[0], port: this.params[0],
host: this.params[6], host: this.params[6],
rootTiddler: this.params[1], roottiddler: this.params[1],
renderType: this.params[2], rendertype: this.params[2],
serveType: this.params[3], servetype: this.params[3],
username: this.params[4], username: this.params[4],
password: this.params[5], password: this.params[5],
pathprefix: this.params[7], pathprefix: this.params[7],
debugLevel: this.params[8] debuglevel: this.params[8]
} }
}); });
var nodeServer = this.server.listen(); var nodeServer = this.server.listen();

View File

@@ -14,7 +14,7 @@ Authenticator for trusted header authentication
function HeaderAuthenticator(server) { function HeaderAuthenticator(server) {
this.server = server; this.server = server;
this.header = server.get("authenticatedUserHeader"); this.header = server.get("authenticateduserheader");
} }
/* /*

View File

@@ -17,8 +17,8 @@ exports.method = "GET";
exports.path = /^\/$/; exports.path = /^\/$/;
exports.handler = function(request,response,state) { exports.handler = function(request,response,state) {
response.writeHead(200, {"Content-Type": state.server.get("serveType")}); response.writeHead(200, {"Content-Type": state.server.get("servetype")});
var text = state.wiki.renderTiddler(state.server.get("renderType"),state.server.get("rootTiddler")); var text = state.wiki.renderTiddler(state.server.get("rendertype"),state.server.get("roottiddler"));
response.end(text,"utf8"); response.end(text,"utf8");
}; };

View File

@@ -62,10 +62,10 @@ function Server(options) {
Server.prototype.defaultVariables = { Server.prototype.defaultVariables = {
port: "8080", port: "8080",
host: "127.0.0.1", host: "127.0.0.1",
rootTiddler: "$:/core/save/all", roottiddler: "$:/core/save/all",
renderType: "text/plain", rendertype: "text/plain",
serveType: "text/html", servetype: "text/html",
debugLevel: "none" debuglevel: "none"
}; };
Server.prototype.get = function(name) { Server.prototype.get = function(name) {
@@ -158,7 +158,7 @@ Server.prototype.requestHandler = function(request,response) {
// Find the route that matches this path // Find the route that matches this path
var route = self.findMatchingRoute(request,state); var route = self.findMatchingRoute(request,state);
// Optionally output debug info // Optionally output debug info
if(self.get("debugLevel") !== "none") { if(self.get("debuglevel") !== "none") {
console.log("Request path:",JSON.stringify(state.urlInfo)); console.log("Request path:",JSON.stringify(state.urlInfo));
console.log("Request headers:",JSON.stringify(request.headers)); console.log("Request headers:",JSON.stringify(request.headers));
console.log("authenticatedUsername:",state.authenticatedUsername); console.log("authenticatedUsername:",state.authenticatedUsername);