chore(backend): update ApPersonService to handle user without endpoint
This commit is contained in:
parent
a6edd50a5d
commit
95b5c47f46
|
@ -534,10 +534,12 @@ export class ApPersonService implements OnModuleInit {
|
||||||
this.hashtagService.updateUsertags(exist, tags);
|
this.hashtagService.updateUsertags(exist, tags);
|
||||||
|
|
||||||
// 該当ユーザーが既にフォロワーになっていた場合はFollowingもアップデートする
|
// 該当ユーザーが既にフォロワーになっていた場合はFollowingもアップデートする
|
||||||
await this.followingsRepository.update(
|
if (person.sharedInbox != null || person.endpoints?.sharedInbox != null) {
|
||||||
{ followerId: exist.id },
|
await this.followingsRepository.update(
|
||||||
{ followerSharedInbox: person.sharedInbox ?? person.endpoints?.sharedInbox },
|
{ followerId: exist.id },
|
||||||
);
|
{ followerSharedInbox: person.sharedInbox ?? person.endpoints?.sharedInbox },
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
await this.updateFeatured(exist.id, resolver).catch(err => this.logger.error(err));
|
await this.updateFeatured(exist.id, resolver).catch(err => this.logger.error(err));
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue