diff --git a/server.js b/server.js index c47442c227..83dd885803 100644 --- a/server.js +++ b/server.js @@ -614,6 +614,13 @@ function(data, match, end, ask) { } }); +// Redirect the root to the website. +camp.route(/^\/$/, function(data, match, end, ask) { + ask.res.statusCode = 302; + ask.res.setHeader('Location', 'http://shields.io'); + ask.res.end(); +}); + // Escapes `t` using the format specified in // function escapeFormat(t) {