mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-03-10 06:30:47 +01:00
Merge branch 'master' into develop
This commit is contained in:
@@ -67,9 +67,7 @@ $(document).ready(function () {
|
||||
apiXHR.abort();
|
||||
}
|
||||
|
||||
if (!window.location.pathname.match(/\/(403|404)$/g)) {
|
||||
app.previousUrl = window.location.href;
|
||||
}
|
||||
app.previousUrl = window.location.href;
|
||||
|
||||
url = ajaxify.start(url);
|
||||
|
||||
|
||||
@@ -21,6 +21,12 @@ define('forum/chats/messages', ['components', 'sounds', 'translator'], function
|
||||
inputEl.val('');
|
||||
inputEl.removeAttr('data-mid');
|
||||
|
||||
$(window).trigger('action:chat.sent', {
|
||||
roomId: roomId,
|
||||
message: msg,
|
||||
mid: mid
|
||||
});
|
||||
|
||||
if (!mid) {
|
||||
socket.emit('modules.chats.send', {
|
||||
roomId: roomId,
|
||||
@@ -145,4 +151,4 @@ define('forum/chats/messages', ['components', 'sounds', 'translator'], function
|
||||
};
|
||||
|
||||
return messages;
|
||||
});
|
||||
});
|
||||
|
||||
@@ -28,7 +28,7 @@ module.exports = function (Categories) {
|
||||
topics[i].index = data.start + i;
|
||||
}
|
||||
|
||||
plugins.fireHook('filter:category.topics.get', {topics: topics, uid: data.uid}, next);
|
||||
plugins.fireHook('filter:category.topics.get', {cid: data.cid, topics: topics, uid: data.uid}, next);
|
||||
},
|
||||
function (results, next) {
|
||||
next(null, {topics: results.topics, nextStart: data.stop + 1});
|
||||
|
||||
@@ -15,7 +15,7 @@ module.exports = function (middleware) {
|
||||
|
||||
middleware.checkGlobalPrivacySettings = function (req, res, next) {
|
||||
if (!req.user && !!parseInt(meta.config.privateUserInfo, 10)) {
|
||||
return controllers.helpers.notAllowed(req, res);
|
||||
return middleware.authenticate(req, res, next);
|
||||
}
|
||||
|
||||
next();
|
||||
|
||||
@@ -272,7 +272,7 @@ module.exports = function (Topics) {
|
||||
db.sortedSetsRemove([
|
||||
'cid:' + topicData.cid + ':tids',
|
||||
'cid:' + topicData.cid + ':tids:pinned',
|
||||
'cid:' + topicData.cid + ':tids:posts'
|
||||
'cid:' + topicData.cid + ':tids:posts' // post count
|
||||
], tid, next);
|
||||
},
|
||||
function (next) {
|
||||
|
||||
Reference in New Issue
Block a user