summaryrefslogtreecommitdiffstats
path: root/pnhandler.js
blob: 41230498470a23b796a3227a91645f57ae618fb0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
/*
 * pnhandler.js
 *
 * group of methods that handles different pathnames
 */

var util = require('util');

function noop(query, res) {
    util.log('[pnhandler] handling ' + query.pathname +
             ', ok who the fuck is messing with us?');
    res.writeHead(200, {'Content-Type': 'text/plain'});
    res.end();
}

function register(query, res) {
    util.log('[pnhandler] handling ' + query.pathname);
    res.writeHead(200, {'Content-Type': 'text/plain'});
    res.end();
}

function login(query, res) {
    util.log('[pnhandler] handling ' + query.pathname);
    res.writeHead(200, {'Content-Type': 'text/plain'});
    res.end();
}

function poll(query, res) {
    util.log('[pnhandler] handling ' + query.pathname);
    res.writeHead(200, {'Content-Type': 'text/plain'});
    res.end();
}

function upload(query, res) {
    util.log('[pnhandler] handling ' + query.pathname);
    res.writeHead(200, {'Content-Type': 'text/plain'});
    res.end();
}

exports.noop = noop;
exports.register = register;
exports.login = login;
exports.poll = poll;
exports.upload = upload;