mirror of
https://github.com/wekan/wekan.git
synced 2026-01-31 05:35:16 +01:00
Use an arrow function inside forEach() instead of an anonymous function
Suggested by deepcode.ai.
This commit is contained in:
parent
06515559a6
commit
b2fee6a6c1
5 changed files with 9 additions and 9 deletions
|
|
@ -365,12 +365,12 @@ BlazeComponent.extendComponent({
|
|||
};
|
||||
currentBoard
|
||||
.cardsInInterval(start.toDate(), end.toDate())
|
||||
.forEach(function(card) {
|
||||
.forEach(card => {
|
||||
pushEvent(card);
|
||||
});
|
||||
currentBoard
|
||||
.cardsDueInBetween(start.toDate(), end.toDate())
|
||||
.forEach(function(card) {
|
||||
.forEach(card => {
|
||||
pushEvent(
|
||||
card,
|
||||
`${card.title} ${TAPi18n.__('card-due')}`,
|
||||
|
|
|
|||
|
|
@ -805,9 +805,9 @@ Template.copyChecklistToManyCardsPopup.events({
|
|||
|
||||
// copy subtasks
|
||||
cursor = Cards.find({ parentId: oldId });
|
||||
cursor.forEach(function() {
|
||||
cursor.forEach(cur => {
|
||||
'use strict';
|
||||
const subtask = arguments[0];
|
||||
const subtask = cur;
|
||||
subtask.parentId = _id;
|
||||
subtask._id = null;
|
||||
/* const newSubtaskId = */ Cards.insert(subtask);
|
||||
|
|
|
|||
|
|
@ -653,7 +653,7 @@ BlazeComponent.extendComponent({
|
|||
'subtext-with-parent',
|
||||
'no-parent',
|
||||
];
|
||||
options.forEach(function(element) {
|
||||
options.forEach(element => {
|
||||
if (element !== value) {
|
||||
$(`#${element} ${MCB}`).toggleClass(CKCLS, false);
|
||||
$(`#${element}`).toggleClass(CKCLS, false);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue