summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsyuilo <4439005+syuilo@users.noreply.github.com>2024-10-13 20:32:02 +0900
committersyuilo <4439005+syuilo@users.noreply.github.com>2024-10-13 20:32:02 +0900
commit5229f5de4d9ef7cd75d32466d29d672193adaf45 (patch)
tree735d17de0669e1538901fb157dfe9430d3dcb10b
parentfeat: リモートサーバーのサーバー情報を収集しないオプ... (diff)
downloadmisskey-5229f5de4d9ef7cd75d32466d29d672193adaf45.tar.gz
misskey-5229f5de4d9ef7cd75d32466d29d672193adaf45.tar.bz2
misskey-5229f5de4d9ef7cd75d32466d29d672193adaf45.zip
refactor(backend): remove unnecessary .then
-rw-r--r--packages/backend/src/core/AbuseReportNotificationService.ts9
-rw-r--r--packages/backend/src/core/AbuseReportService.ts6
-rw-r--r--packages/backend/src/core/SignupService.ts4
-rw-r--r--packages/backend/src/core/SystemWebhookService.ts9
4 files changed, 10 insertions, 18 deletions
diff --git a/packages/backend/src/core/AbuseReportNotificationService.ts b/packages/backend/src/core/AbuseReportNotificationService.ts
index 7d030f2f16..25e265f2b1 100644
--- a/packages/backend/src/core/AbuseReportNotificationService.ts
+++ b/packages/backend/src/core/AbuseReportNotificationService.ts
@@ -288,8 +288,7 @@ export class AbuseReportNotificationService implements OnApplicationShutdown {
.log(updater, 'createAbuseReportNotificationRecipient', {
recipientId: id,
recipient: created,
- })
- .then();
+ });
return created;
}
@@ -327,8 +326,7 @@ export class AbuseReportNotificationService implements OnApplicationShutdown {
recipientId: params.id,
before: beforeEntity,
after: afterEntity,
- })
- .then();
+ });
return afterEntity;
}
@@ -349,8 +347,7 @@ export class AbuseReportNotificationService implements OnApplicationShutdown {
.log(updater, 'deleteAbuseReportNotificationRecipient', {
recipientId: id,
recipient: entity,
- })
- .then();
+ });
}
/**
diff --git a/packages/backend/src/core/AbuseReportService.ts b/packages/backend/src/core/AbuseReportService.ts
index 73baad5499..0b022d3b08 100644
--- a/packages/backend/src/core/AbuseReportService.ts
+++ b/packages/backend/src/core/AbuseReportService.ts
@@ -110,8 +110,7 @@ export class AbuseReportService {
reportId: report.id,
report: report,
resolvedAs: ps.resolvedAs,
- })
- .then();
+ });
}
return this.abuseUserReportsRepository.findBy({ id: In(reports.map(it => it.id)) })
@@ -148,8 +147,7 @@ export class AbuseReportService {
.log(moderator, 'forwardAbuseReport', {
reportId: report.id,
report: report,
- })
- .then();
+ });
}
@bindThis
diff --git a/packages/backend/src/core/SignupService.ts b/packages/backend/src/core/SignupService.ts
index cc8a3d6461..3865392b7f 100644
--- a/packages/backend/src/core/SignupService.ts
+++ b/packages/backend/src/core/SignupService.ts
@@ -150,8 +150,8 @@ export class SignupService {
}));
});
- this.usersChart.update(account, true).then();
- this.userService.notifySystemWebhook(account, 'userCreated').then();
+ this.usersChart.update(account, true);
+ this.userService.notifySystemWebhook(account, 'userCreated');
return { account, secret };
}
diff --git a/packages/backend/src/core/SystemWebhookService.ts b/packages/backend/src/core/SystemWebhookService.ts
index bb7c6b8c0e..db6407dcb3 100644
--- a/packages/backend/src/core/SystemWebhookService.ts
+++ b/packages/backend/src/core/SystemWebhookService.ts
@@ -101,8 +101,7 @@ export class SystemWebhookService implements OnApplicationShutdown {
.log(updater, 'createSystemWebhook', {
systemWebhookId: webhook.id,
webhook: webhook,
- })
- .then();
+ });
return webhook;
}
@@ -139,8 +138,7 @@ export class SystemWebhookService implements OnApplicationShutdown {
systemWebhookId: beforeEntity.id,
before: beforeEntity,
after: afterEntity,
- })
- .then();
+ });
return afterEntity;
}
@@ -158,8 +156,7 @@ export class SystemWebhookService implements OnApplicationShutdown {
.log(updater, 'deleteSystemWebhook', {
systemWebhookId: webhook.id,
webhook,
- })
- .then();
+ });
}
/**