v1.18.x
barisusakli 9 years ago
parent 5e1bd58a02
commit 488f147bef

@ -61,7 +61,7 @@
"rss": "^1.0.0", "rss": "^1.0.0",
"semver": "^5.0.1", "semver": "^5.0.1",
"serve-favicon": "^2.1.5", "serve-favicon": "^2.1.5",
"sitemap": "^1.0.0", "sitemap": "^1.4.0",
"socket.io": "^1.2.1", "socket.io": "^1.2.1",
"socket.io-client": "^1.2.1", "socket.io-client": "^1.2.1",
"socket.io-redis": "^0.1.3", "socket.io-redis": "^0.1.3",

@ -168,7 +168,10 @@ Controllers.sitemap = function(req, res, next) {
var sitemap = require('../sitemap.js'); var sitemap = require('../sitemap.js');
sitemap.render(function(xml) { sitemap.render(function(err, xml) {
if (err) {
return next(err);
}
res.header('Content-Type', 'application/xml'); res.header('Content-Type', 'application/xml');
res.send(xml); res.send(xml);
}); });

Loading…
Cancel
Save