chore: eslint prefer-arrow-callback

This commit is contained in:
Peter Jaszkowiak
2021-02-04 00:01:39 -07:00
committed by Julian Lam
parent 707b55b6a5
commit b56d9e12b5
334 changed files with 4995 additions and 5182 deletions

View File

@@ -112,7 +112,7 @@ Topics.getTopicsByTids = async function (tids, options) {
]);
const sortOldToNew = callerSettings.topicPostSort === 'newest_to_oldest';
result.topics.forEach(function (topic, i) {
result.topics.forEach((topic, i) => {
if (topic) {
topic.thumbs = result.thumbs[i];
topic.category = result.categoriesMap[topic.cid];
@@ -280,7 +280,7 @@ Topics.getMainPosts = async function (tids, uid) {
async function getMainPosts(mainPids, uid) {
const postData = await posts.getPostsByPids(mainPids, uid);
postData.forEach(function (post) {
postData.forEach((post) => {
if (post) {
post.index = 0;
}