require("babel-register");
require("babel-polyfill");

var restify = require('restify');
var server = restify.createServer({name: 'Webshotify'});

server.use(restify.fullResponse());
server.use(restify.bodyParser());
server.use(restify.queryParser());

var port = normalizePort(process.env.NODE_PORT) || 3000;

server.listen(port, function() {
    console.log('%s listening at %s', server.name, server.url);
});

var routes = require('./routes')['default'](server);

function normalizePort(val) {
    var port = parseInt(val, 10);

    if (isNaN(port)) {
        // named pipe
        return val;
    }

    if (port >= 0) {
        // port number
        return port;
    }

    return false;
}

@@ -244,16 +244,79 @@
 rser());
+%0Aserver.use(restify.throttle(%7Bburst: 20, rate: 10, ip: true%7D));
 %0A%0Avar po
@@ -395,16 +395,17 @@
 function
+ 
 () %7B%0A   

use restify's throttle plugin