remove body parser altogether

This commit is contained in:
jane 2021-06-06 02:26:21 -04:00
parent aed5b034a9
commit 3e36e1dd21
2 changed files with 1 additions and 8 deletions

View File

@ -58,8 +58,6 @@ app.get("/indexes/:project(\\w+)", (req, res) => {
res.sendStatus(404);
}
});
app.use(express.urlencoded({ extended: false }));
app.use(express.text());
function diff(current, checked) {
let lines_current = current.split('\n').map(l => l.trim()).filter(l => l != "");

View File

@ -69,12 +69,7 @@ local function getAllFiles(program)
print("#DEBUG currentFiles " .. currentFiles)
local updateResult = http.post(updateUrl, {
content = currentFiles
}, {
["Content-Type"] = "text/plain",
["Content-Length"] = #currentFiles
})
local updateResult = http.post(updateUrl, currentFiles)
if updateResult == nil then
print("error! getting updates for " .. program)
error()