• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

khu-khlug / sight-backend / 13816765552

12 Mar 2025 04:40PM UTC coverage: 51.16% (+0.2%) from 50.926%
13816765552

push

github

web-flow
feat: 회원 탈퇴 기능 구현 (#112)

781 of 2476 branches covered (31.54%)

Branch coverage included in aggregate %.

28 of 55 new or added lines in 8 files covered. (50.91%)

56 existing lines in 7 files now uncovered.

2175 of 3302 relevant lines covered (65.87%)

12.91 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

67.21
/src/app/application/user/command/removeDiscordIntegration/RemoveDiscordIntegrationCommandHandler.ts
1
import { Inject, NotFoundException } from '@nestjs/common';
2
import { CommandHandler, ICommandHandler } from '@nestjs/cqrs';
1✔
3

4
import { RemoveDiscordIntegrationCommand } from '@khlug/app/application/user/command/removeDiscordIntegration/RemoveDiscordIntegrationCommand';
5
import { DiscordMemberService } from '@khlug/app/application/user/service/DiscordMemberService';
1✔
6

7
import {
8
  DiscordIntegrationRepositoryToken,
4✔
9
  IDiscordIntegrationRepository,
10
} from '@khlug/app/domain/discord/IDiscordIntegrationRepository';
11

1✔
12
import { Message } from '@khlug/constant/message';
1✔
13

1✔
14
@CommandHandler(RemoveDiscordIntegrationCommand)
1✔
15
export class RemoveDiscordIntegrationCommandHandler
1✔
16
  implements ICommandHandler<RemoveDiscordIntegrationCommand>
1✔
17
{
18
  constructor(
4!
19
    @Inject(DiscordIntegrationRepositoryToken)
×
20
    private readonly discordIntegrationRepository: IDiscordIntegrationRepository,
21
    private readonly discordMemberService: DiscordMemberService,
22
  ) {}
23

24
  async execute(command: RemoveDiscordIntegrationCommand): Promise<void> {
25
    const { userId } = command;
26

4✔
27
    const discordIntegration =
28
      await this.discordIntegrationRepository.findByUserId(userId);
4✔
29
    if (!discordIntegration) {
30
      throw new NotFoundException(Message.DISCORD_INTEGRATION_NOT_FOUND);
31
    }
1!
32

1!
NEW
33
    await this.discordMemberService.clearDiscordIntegration(userId);
×
34
  }
1!
35
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc