refactor(ApMentionService.ts)

This commit is contained in:
okayurisotto 2023-07-02 12:24:24 +09:00
parent c9adcfa6fa
commit 9889ad6eb9

View File

@ -22,8 +22,8 @@ export class ApMentionService {
}
@bindThis
public async extractApMentions(tags: IObject | IObject[] | null | undefined, resolver: Resolver) {
const hrefs = unique(this.extractApMentionObjects(tags).map(x => x.href as string));
public async extractApMentions(tags: IObject | IObject[] | null | undefined, resolver: Resolver): Promise<User[]> {
const hrefs = unique(this.extractApMentionObjects(tags).map(x => x.href));
const limit = promiseLimit<User | null>(2);
const mentionedUsers = (await Promise.all(