mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-01-11 01:52:55 +01:00
fix: if reputation is disabled hide votes on /recent
they were only hidden on category page
This commit is contained in:
@@ -106,10 +106,10 @@
|
||||
"nodebb-plugin-spam-be-gone": "2.3.2",
|
||||
"nodebb-plugin-web-push": "0.7.5",
|
||||
"nodebb-rewards-essentials": "1.0.2",
|
||||
"nodebb-theme-harmony": "2.1.18",
|
||||
"nodebb-theme-harmony": "2.1.19",
|
||||
"nodebb-theme-lavender": "7.1.19",
|
||||
"nodebb-theme-peace": "2.2.48",
|
||||
"nodebb-theme-persona": "14.1.12",
|
||||
"nodebb-theme-persona": "14.1.13",
|
||||
"nodebb-widget-essentials": "7.0.40",
|
||||
"nodemailer": "7.0.6",
|
||||
"nprogress": "0.2.0",
|
||||
|
||||
@@ -53,7 +53,7 @@ define('topicList', [
|
||||
|
||||
handleBack.init(function (after, handleBackCallback) {
|
||||
loadTopicsCallback(after, 1, function (data, loadCallback) {
|
||||
onTopicsLoaded(templateName, data.topics, ajaxify.data.showSelect, 1, function () {
|
||||
onTopicsLoaded(templateName, data, ajaxify.data.showSelect, 1, function () {
|
||||
handleBackCallback();
|
||||
loadCallback();
|
||||
});
|
||||
@@ -166,7 +166,7 @@ define('topicList', [
|
||||
}
|
||||
|
||||
loadTopicsCallback(after, direction, function (data, done) {
|
||||
onTopicsLoaded(templateName, data.topics, ajaxify.data.showSelect, direction, done);
|
||||
onTopicsLoaded(templateName, data, ajaxify.data.showSelect, direction, done);
|
||||
});
|
||||
};
|
||||
|
||||
@@ -187,7 +187,8 @@ define('topicList', [
|
||||
});
|
||||
}
|
||||
|
||||
function onTopicsLoaded(templateName, topics, showSelect, direction, callback) {
|
||||
function onTopicsLoaded(templateName, data, showSelect, direction, callback) {
|
||||
let { topics } = data;
|
||||
if (!topics || !topics.length) {
|
||||
$('#load-more-btn').hide();
|
||||
return callback();
|
||||
@@ -212,6 +213,7 @@ define('topicList', [
|
||||
const tplData = {
|
||||
topics: topics,
|
||||
showSelect: showSelect,
|
||||
'reputation:disabled': data['reputation:disabled'],
|
||||
template: {
|
||||
name: templateName,
|
||||
},
|
||||
|
||||
@@ -79,6 +79,7 @@ recentController.getData = async function (req, url, sort) {
|
||||
data.selectedTag = tagData.selectedTag;
|
||||
data.selectedTags = tagData.selectedTags;
|
||||
data['feeds:disableRSS'] = meta.config['feeds:disableRSS'] || 0;
|
||||
data['reputation:disabled'] = meta.config['reputation:disabled'];
|
||||
if (!meta.config['feeds:disableRSS']) {
|
||||
data.rssFeedUrl = `${relative_path}/${url}.rss`;
|
||||
if (req.loggedIn) {
|
||||
|
||||
Reference in New Issue
Block a user