From 5f7cd5ece5c5a94d1d6ecb26d314bb4015244468 Mon Sep 17 00:00:00 2001 From: Henry Oswald Date: Wed, 20 Apr 2016 15:38:05 +0100 Subject: [PATCH] added project status endpoint used for getting the server a project is on --- app.coffee | 1 + app/coffee/CompileController.coffee | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/app.coffee b/app.coffee index f94685a..aaa2b7e 100644 --- a/app.coffee +++ b/app.coffee @@ -48,6 +48,7 @@ app.delete "/project/:project_id", CompileController.clearCache app.get "/project/:project_id/sync/code", CompileController.syncFromCode app.get "/project/:project_id/sync/pdf", CompileController.syncFromPdf app.get "/project/:project_id/wordcount", CompileController.wordcount +app.get "/project/:project_id/status", CompileController.status ForbidSymlinks = require "./app/js/StaticServerForbidSymlinks" diff --git a/app/coffee/CompileController.coffee b/app/coffee/CompileController.coffee index dd73040..62b1020 100644 --- a/app/coffee/CompileController.coffee +++ b/app/coffee/CompileController.coffee @@ -78,3 +78,7 @@ module.exports = CompileController = res.send JSON.stringify { texcount: result } + + status: (req, res, next = (error)-> )-> + res.send("OK") +