Skip to content

Commit

Permalink
fix: event to original time
Browse files Browse the repository at this point in the history
  • Loading branch information
kyeahxx19 committed Mar 22, 2024
1 parent 73503c6 commit 0b64119
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 11 deletions.
6 changes: 2 additions & 4 deletions src/event/event.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,9 @@ export class EventController {
return 2;
}
if (
// debug
eventUser?.group &&
eventUser?.group?.createdAt >
new Date(new Date().getTime() - 1000 * 60 * 3 + 1000 * 60 * 60 * 9)
new Date(new Date().getTime() - 1000 * 60 * 15 + 1000 * 60 * 60 * 9)
) {
return 1;
}
Expand Down Expand Up @@ -151,9 +150,8 @@ export class EventController {
const eventUser = await this.eventService.getEventInfo(user);

if (
// debug
eventUser.group.createdAt >
new Date(new Date().getTime() + 1000 * 60 * 60 * 9 - 1000 * 60 * 5)
new Date(new Date().getTime() + 1000 * 60 * 60 * 9 - 1000 * 60 * 20)
) {
throw new HttpException('화살 보내기가 끝나지 않았습니다', 400);
}
Expand Down
7 changes: 0 additions & 7 deletions src/event/event.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ import { FcmService } from 'src/firebase/fcm.service';
import { UserService } from 'src/user/user.service';
import { Repository } from 'typeorm';
import { Sex } from 'src/common/enums';
import { BlurtingService } from 'src/blurting/blurting.service';
import { ArrowInfoResponseDto } from 'src/blurting/dtos/arrowInfoResponse.dto';
import { OtherPeopleInfoDto } from 'src/blurting/dtos/otherPeopleInfo.dto';
import axios from 'axios';
Expand Down Expand Up @@ -132,12 +131,6 @@ export class EventService {
}

async registerGroupQueue(id: number) {
// debug
if (id > 0) {
await this.createGroup([id]);
return 1;
}

try {
const user = await this.userService.findUserByVal('id', id);
const sex = user.userInfo.sex;
Expand Down

0 comments on commit 0b64119

Please sign in to comment.