mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-12-20 23:40:38 +01:00
Merge remote-tracking branch 'origin/master' into require.js
This commit is contained in:
@@ -376,7 +376,8 @@ define('forum/topic', ['forum/pagination', 'forum/infinitescroll', 'forum/topic/
|
|||||||
}
|
}
|
||||||
|
|
||||||
function loadPostsAfter(after, callback) {
|
function loadPostsAfter(after, callback) {
|
||||||
if (!utils.isNumber(after) || (after === 0 && $('#post-container li.post-row[data-index="0"]').length)) {
|
var tid = ajaxify.variables.get('topic_id');
|
||||||
|
if (!utils.isNumber(tid) || !utils.isNumber(after) || (after === 0 && $('#post-container li.post-row[data-index="0"]').length)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -386,7 +387,7 @@ define('forum/topic', ['forum/pagination', 'forum/infinitescroll', 'forum/topic/
|
|||||||
}
|
}
|
||||||
|
|
||||||
infinitescroll.loadMore('topics.loadMore', {
|
infinitescroll.loadMore('topics.loadMore', {
|
||||||
tid: ajaxify.variables.get('topic_id'),
|
tid: tid,
|
||||||
after: after
|
after: after
|
||||||
}, function (data) {
|
}, function (data) {
|
||||||
|
|
||||||
|
|||||||
@@ -65,6 +65,7 @@
|
|||||||
|
|
||||||
redisClient.on('error', function (err) {
|
redisClient.on('error', function (err) {
|
||||||
winston.error(err.stack);
|
winston.error(err.stack);
|
||||||
|
process.exit(1);
|
||||||
});
|
});
|
||||||
|
|
||||||
module.client = redisClient;
|
module.client = redisClient;
|
||||||
|
|||||||
@@ -29,12 +29,12 @@ var path = require('path'),
|
|||||||
async.parallel([
|
async.parallel([
|
||||||
function(next) {
|
function(next) {
|
||||||
var categoryUrls = [];
|
var categoryUrls = [];
|
||||||
categories.getVisibleCategories(0, function(err, data) {
|
categories.getVisibleCategories(0, function(err, categoriesData) {
|
||||||
if (err) {
|
if (err) {
|
||||||
return next(err);
|
return next(err);
|
||||||
}
|
}
|
||||||
|
|
||||||
data.categories.forEach(function(category) {
|
categoriesData.forEach(function(category) {
|
||||||
categoryUrls.push({
|
categoryUrls.push({
|
||||||
url: path.join('/category', category.slug),
|
url: path.join('/category', category.slug),
|
||||||
changefreq: 'weekly',
|
changefreq: 'weekly',
|
||||||
|
|||||||
Reference in New Issue
Block a user