From 68e8892f61b94e06724591d5e355c73463cfb40c Mon Sep 17 00:00:00 2001 From: syuilo Date: Sat, 8 Apr 2023 14:18:28 +0900 Subject: [PATCH] chore: use for instead of forEach --- packages/backend/src/core/AccountMoveService.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/backend/src/core/AccountMoveService.ts b/packages/backend/src/core/AccountMoveService.ts index 6a7727c57..3f2a19b77 100644 --- a/packages/backend/src/core/AccountMoveService.ts +++ b/packages/backend/src/core/AccountMoveService.ts @@ -72,17 +72,17 @@ export class AccountMoveService { where: { followeeId: src.id, followerHost: IsNull(), // follower is local - } + }, }); - followings.forEach(async (following) => { - if (!following.follower) return; + for (const following of followings) { + if (!following.follower) continue; try { await this.userFollowingService.follow(following.follower, dst); await this.userFollowingService.unfollow(following.follower, src); } catch { /* empty */ } - }); + } return iObj; }