From bfa0fcd6f01a6e519ea0c68017358f9980d2ed96 Mon Sep 17 00:00:00 2001 From: okayurisotto Date: Mon, 3 Jul 2023 20:41:09 +0900 Subject: [PATCH] =?UTF-8?q?refactor(`ApPersonService.ts`):=20=E8=BF=94?= =?UTF-8?q?=E3=82=8A=E5=80=A4=E3=82=92`void`=E3=81=AB=E7=B5=B1=E4=B8=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit この返り値を参照しているコードは見当たらなかった。 また、普通に意味がない値であるように見受けられた。 --- .../backend/src/core/activitypub/models/ApPersonService.ts | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/packages/backend/src/core/activitypub/models/ApPersonService.ts b/packages/backend/src/core/activitypub/models/ApPersonService.ts index 57298eaee9..912477c9fe 100644 --- a/packages/backend/src/core/activitypub/models/ApPersonService.ts +++ b/packages/backend/src/core/activitypub/models/ApPersonService.ts @@ -397,7 +397,7 @@ export class ApPersonService implements OnModuleInit { * @param movePreventUris ここに指定されたURIがPersonのmovedToに指定されていたり10回より多く回っている場合これ以上アカウント移行を行わない(無限ループ防止) */ @bindThis - public async updatePerson(uri: string, resolver?: Resolver | null, hint?: IObject, movePreventUris: string[] = []): Promise { + public async updatePerson(uri: string, resolver?: Resolver | null, hint?: IObject, movePreventUris: string[] = []): Promise { if (typeof uri !== 'string') throw new Error('uri is not string'); // URIがこのサーバーを指しているならスキップ @@ -536,17 +536,14 @@ export class ApPersonService implements OnModuleInit { exist.movedAt.getTime() + 1000 * 60 * 60 * 24 * 14 < updated.movedAt.getTime() )) { this.logger.info(`Start to process Move of @${updated.username}@${updated.host} (${uri})`); - return this.processRemoteMove(updated, movePreventUris) + await this.processRemoteMove(updated, movePreventUris) .then(result => { this.logger.info(`Processing Move Finished [${result}] @${updated.username}@${updated.host} (${uri})`); - return result; }) .catch(e => { this.logger.info(`Processing Move Failed @${updated.username}@${updated.host} (${uri})`, { stack: e }); }); } - - return 'skip'; } /**