mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-18 03:31:03 +01:00
Merge branch 'master' of https://github.com/designcreateplay/NodeBB
This commit is contained in:
@@ -121,13 +121,11 @@ var express = require('express'),
|
||||
if (tid.match('.rss')) {
|
||||
fs.readFile('feeds/topics/' + tid, function (err, data) {
|
||||
if (err) {
|
||||
res.send("Unable to locate an rss feed at this location.");
|
||||
res.type('text').send(404, "Unable to locate an rss feed at this location.");
|
||||
return;
|
||||
}
|
||||
|
||||
res.setHeader('Content-Type', 'application/xml');
|
||||
res.setHeader('Content-Length', data.length);
|
||||
res.end(data);
|
||||
res.type('xml').set('Content-Length', data.length).send(data);
|
||||
});
|
||||
return;
|
||||
}
|
||||
@@ -149,13 +147,11 @@ var express = require('express'),
|
||||
if (cid.match('.rss')) {
|
||||
fs.readFile('feeds/categories/' + cid, function (err, data) {
|
||||
if (err) {
|
||||
res.send("Unable to locate an rss feed at this location.");
|
||||
res.type('text').send(404, "Unable to locate an rss feed at this location.");
|
||||
return;
|
||||
}
|
||||
|
||||
res.setHeader('Content-Type', 'application/xml');
|
||||
res.setHeader('Content-Length', data.length);
|
||||
res.end(data);
|
||||
res.type('xml').set('Content-Length', data.length).send(data);
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user