now trims posts

This commit is contained in:
Mystikfluu 2022-05-25 17:35:59 +02:00
parent a6743bcb07
commit 531b0cab53

View File

@ -257,6 +257,7 @@ router.get("/api/getotheruser",async function(req,res) {
})
router.post("/api/post", async function(req,res) {
req.body.message = req.body.message.trim()
if(!req.body.message) {
res.json({"error":"no message to post"})
return