0
0
This commit is contained in:
syuilo 2023-04-22 20:12:41 +09:00
parent 8876ae09ed
commit b57ee4dd96

View File

@ -66,7 +66,15 @@ export class FederatedInstanceService {
@bindThis
public async update(id: Instance['id'], data: Partial<Instance>): Promise<void> {
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);