summaryrefslogtreecommitdiff
path: root/src/services/note/reaction/create.ts
diff options
context:
space:
mode:
authorAya Morisawa <AyaMorisawa4869@gmail.com>2018-12-11 20:36:55 +0900
committerGitHub <noreply@github.com>2018-12-11 20:36:55 +0900
commit125849673a1aba46021852ee473d00f4520d1bd6 (patch)
treee30d39490236df402b97a9963dafa44eaf549368 /src/services/note/reaction/create.ts
parentFix error (diff)
downloadmisskey-125849673a1aba46021852ee473d00f4520d1bd6.tar.gz
misskey-125849673a1aba46021852ee473d00f4520d1bd6.tar.bz2
misskey-125849673a1aba46021852ee473d00f4520d1bd6.zip
Use for-of instead of forEach (#3583)
Co-authored-by: syuilo <syuilotan@yahoo.co.jp> Co-authored-by: Acid Chicken (硫酸鶏) <root@acid-chicken.com>
Diffstat (limited to 'src/services/note/reaction/create.ts')
-rw-r--r--src/services/note/reaction/create.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/services/note/reaction/create.ts b/src/services/note/reaction/create.ts
index 4a09cf535f..4f56f399a8 100644
--- a/src/services/note/reaction/create.ts
+++ b/src/services/note/reaction/create.ts
@@ -70,12 +70,12 @@ export default async (user: IUser, note: INote, reaction: string) => new Promise
}
})
.then(watchers => {
- watchers.forEach(watcher => {
+ for (const watcher of watchers) {
notify(watcher.userId, user._id, 'reaction', {
noteId: note._id,
reaction: reaction
});
- });
+ }
});
// ユーザーがローカルユーザーかつ自動ウォッチ設定がオンならばこの投稿をWatchする