From b57ee4dd9686196ce353e9eb469ba0b81f921c7b Mon Sep 17 00:00:00 2001 From: syuilo Date: Sat, 22 Apr 2023 20:12:41 +0900 Subject: [PATCH] fix of 34492f3c9a --- packages/backend/src/core/FederatedInstanceService.ts | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/packages/backend/src/core/FederatedInstanceService.ts b/packages/backend/src/core/FederatedInstanceService.ts index 1ead73b25a..2049bd4c60 100644 --- a/packages/backend/src/core/FederatedInstanceService.ts +++ b/packages/backend/src/core/FederatedInstanceService.ts @@ -66,7 +66,15 @@ export class FederatedInstanceService { @bindThis public async update(id: Instance['id'], data: Partial): Promise { - const result = await this.instancesRepository.update(id, data); + const result = await this.instancesRepository.createQueryBuilder().update() + .set(data) + .where('id = :id', { id }) + .returning('*') + .execute() + .then((response) => { + return response.raw[0]; + }); + const updated = result.raw[0]; this.federatedInstanceCache.set(updated.host, updated);