Express.js get http method in controller

Solution 1:

The answer was quite easy

exports.register = function(req, res) {
    if (req.method == "POST") {
       // do form handling
    }
    res.render('user/registration.html.swig', { form: form.toHTML() });
};

But I searched a long time for this approach in the express guide.

Finally the node documentation has such detailed information: http://nodejs.org/api/http.html#http_http_request_options_callback