mirror of
https://github.com/misskey-dev/misskey.git
synced 2024-12-27 08:10:24 +01:00
reversi-matching
This commit is contained in:
parent
6b72d888f8
commit
f8df218bbb
1 changed files with 2 additions and 4 deletions
|
@ -3,16 +3,14 @@ import { ReversiMatching } from '@/models/entities/games/reversi/matching';
|
|||
import { Users } from '../../../index';
|
||||
import { awaitAll } from '@/prelude/await-all';
|
||||
import { User } from '@/models/entities/user';
|
||||
import { SchemaType } from '@/misc/schema';
|
||||
|
||||
export type PackedReversiMatching = SchemaType<typeof packedReversiMatchingSchema>;
|
||||
import { Packed } from '@/misc/schema';
|
||||
|
||||
@EntityRepository(ReversiMatching)
|
||||
export class ReversiMatchingRepository extends Repository<ReversiMatching> {
|
||||
public async pack(
|
||||
src: ReversiMatching['id'] | ReversiMatching,
|
||||
me: { id: User['id'] }
|
||||
): Promise<PackedReversiMatching> {
|
||||
): Promise<Packed<'ReversiMatching'>> {
|
||||
const matching = typeof src === 'object' ? src : await this.findOneOrFail(src);
|
||||
|
||||
return await awaitAll({
|
||||
|
|
Loading…
Reference in a new issue