1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2025-10-31 23:53:00 +00:00

Refactor module locations

This commit is contained in:
Jermolene
2018-06-22 22:02:57 +01:00
parent 1eea89f138
commit b70ebadda5
11 changed files with 11 additions and 11 deletions

View File

@@ -0,0 +1,31 @@
/*\
title: $:/core/modules/server/routes/get-status.js
type: application/javascript
module-type: serverroute
GET /status
\*/
(function() {
/*jslint node: true, browser: true */
/*global $tw: false */
"use strict";
exports.method = "GET";
exports.path = /^\/status$/;
exports.handler = function(request,response,state) {
response.writeHead(200, {"Content-Type": "application/json"});
var text = JSON.stringify({
username: state.authenticatedUsername,
space: {
recipe: "default"
},
tiddlywiki_version: $tw.version
});
response.end(text,"utf8");
};
}());