Skip to content

Commit 39d9f54

Browse files
author
github-actions
committed
chore: Java 스타일 수정
1 parent 655929e commit 39d9f54

File tree

4 files changed

+15
-13
lines changed

4 files changed

+15
-13
lines changed

backend/src/main/java/io/f1/backend/domain/game/app/GameService.java

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
import static io.f1.backend.domain.game.mapper.RoomMapper.toQuestionStartResponse;
66
import static io.f1.backend.domain.quiz.mapper.QuizMapper.toGameStartResponse;
77

8-
import io.f1.backend.domain.game.dto.request.GameSettingChanger;
98
import io.f1.backend.domain.game.dto.MessageType;
9+
import io.f1.backend.domain.game.dto.request.GameSettingChanger;
1010
import io.f1.backend.domain.game.dto.response.PlayerListResponse;
1111
import io.f1.backend.domain.game.event.RoomUpdatedEvent;
1212
import io.f1.backend.domain.game.model.Player;
@@ -23,8 +23,8 @@
2323
import io.f1.backend.global.exception.errorcode.RoomErrorCode;
2424

2525
import lombok.RequiredArgsConstructor;
26-
2726
import lombok.extern.slf4j.Slf4j;
27+
2828
import org.springframework.context.ApplicationEventPublisher;
2929
import org.springframework.stereotype.Service;
3030

@@ -101,8 +101,10 @@ public void changeGameSetting(
101101

102102
broadcastGameSetting(room);
103103

104-
RoomUpdatedEvent roomUpdatedEvent = new RoomUpdatedEvent(room,
105-
quizService.getQuizWithQuestionsById(room.getGameSetting().getQuizId()));
104+
RoomUpdatedEvent roomUpdatedEvent =
105+
new RoomUpdatedEvent(
106+
room,
107+
quizService.getQuizWithQuestionsById(room.getGameSetting().getQuizId()));
106108

107109
eventPublisher.publishEvent(roomUpdatedEvent);
108110
}
@@ -160,8 +162,8 @@ private void broadcastGameSetting(Room room) {
160162
String destination = getDestination(room.getId());
161163
Quiz quiz = quizService.getQuizWithQuestionsById(room.getGameSetting().getQuizId());
162164
messageSender.send(
163-
destination,
164-
MessageType.GAME_SETTING,
165-
toGameSettingResponse(room.getGameSetting(), quiz));
165+
destination,
166+
MessageType.GAME_SETTING,
167+
toGameSettingResponse(room.getGameSetting(), quiz));
166168
}
167169
}

backend/src/main/java/io/f1/backend/domain/game/dto/request/QuizChangeRequest.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,18 @@
11
package io.f1.backend.domain.game.dto.request;
22

3+
import static io.f1.backend.domain.game.mapper.RoomMapper.toPlayerListResponse;
4+
import static io.f1.backend.domain.game.websocket.WebSocketUtils.getDestination;
5+
36
import io.f1.backend.domain.game.dto.MessageType;
47
import io.f1.backend.domain.game.dto.response.PlayerListResponse;
58
import io.f1.backend.domain.game.model.Room;
69
import io.f1.backend.domain.game.websocket.MessageSender;
710
import io.f1.backend.domain.quiz.app.QuizService;
811
import io.f1.backend.domain.quiz.entity.Quiz;
912

10-
import java.util.Objects;
1113
import lombok.extern.slf4j.Slf4j;
1214

13-
import static io.f1.backend.domain.game.mapper.RoomMapper.toPlayerListResponse;
14-
import static io.f1.backend.domain.game.websocket.WebSocketUtils.getDestination;
15+
import java.util.Objects;
1516

1617
@Slf4j
1718
public record QuizChangeRequest(Long quizId) implements GameSettingChanger {

backend/src/main/java/io/f1/backend/domain/game/model/Room.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
import io.f1.backend.domain.game.dto.request.TimeLimit;
44
import io.f1.backend.domain.question.entity.Question;
5-
65
import io.f1.backend.domain.quiz.entity.Quiz;
6+
77
import lombok.Getter;
88

99
import java.time.LocalDateTime;
@@ -129,5 +129,4 @@ public int getTimeLimit() {
129129
public int getRound() {
130130
return gameSetting.getRound();
131131
}
132-
133132
}

backend/src/main/java/io/f1/backend/domain/game/websocket/GameSocketController.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@
66
import io.f1.backend.domain.game.app.GameService;
77
import io.f1.backend.domain.game.app.RoomService;
88
import io.f1.backend.domain.game.dto.ChatMessage;
9+
import io.f1.backend.domain.game.dto.request.DefaultWebSocketRequest;
910
import io.f1.backend.domain.game.dto.request.QuizChangeRequest;
1011
import io.f1.backend.domain.game.dto.request.RoundChangeRequest;
1112
import io.f1.backend.domain.game.dto.request.TimeLimitChangeRequest;
12-
import io.f1.backend.domain.game.dto.request.DefaultWebSocketRequest;
1313
import io.f1.backend.domain.user.dto.UserPrincipal;
1414

1515
import lombok.RequiredArgsConstructor;

0 commit comments

Comments
 (0)