Skip to content

Commit

Permalink
feat: 예외처리 기능-1 #78
Browse files Browse the repository at this point in the history
  • Loading branch information
yhpark95 committed Nov 7, 2023
1 parent 9914a66 commit 7b6786a
Showing 1 changed file with 1 addition and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
package codesquad.gaemimarble.game.controller;

import java.io.IOException;
import java.util.HashSet;
import java.util.Set;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentMap;

Expand Down Expand Up @@ -42,8 +40,7 @@ public boolean saveSocket(Long gameId, String playerId, WebSocketSession session
boolean isDuplicate = socketMap.containsKey(playerId);

if (!isDuplicate) {
session.getAttributes().put("playerId", playerId);
sessions.add(session);
socketMap.put(playerId, session);
return true;
} else {
session.sendMessage(new TextMessage(objectMapper.writeValueAsString(
Expand Down

0 comments on commit 7b6786a

Please sign in to comment.