feat(frontend): Misskey Gamesのリストに鯖缶指定のチャンネルを載せる (MisskeyIO#383)
This commit is contained in:
parent
7884901950
commit
ac79f1fdc1
24 changed files with 232 additions and 13 deletions
|
@ -97,5 +97,14 @@ export class ChannelEntityService {
|
|||
} : {}),
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
public async packMany(
|
||||
channels: (MiChannel['id'] | MiChannel)[],
|
||||
me: { id: MiUser['id'] } | null | undefined,
|
||||
detailed?: boolean,
|
||||
): Promise<Packed<'Channel'>[]> {
|
||||
return (await Promise.allSettled(channels.map(x => this.pack(x, me, detailed))))
|
||||
.filter(result => result.status === 'fulfilled')
|
||||
.map(result => (result as PromiseFulfilledResult<Packed<'Channel'>>).value);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue