overleaf/services/web/app/coffee/Features/User/UserController.coffee

10 lines
No EOL
213 B
CoffeeScript

UserDeleter = require("./UserDeleter")
module.exports =
deleteUser: (req, res)->
user_id = req.session.user._id
UserDeleter.deleteUser user_id, (err)->
if !err?
req.session.destroy()
res.send(200)