Skip to content

Commit 2f6ad8d

Browse files
fix: 유저 정보 업데이트 삭제 (#74)
* refactor: ♻️ validation 고도화 (#72) * fix: 유저 정보 업데이트 삭제
1 parent 293b702 commit 2f6ad8d

File tree

1 file changed

+1
-18
lines changed

1 file changed

+1
-18
lines changed

src/main/java/com/goormdari/domain/user/presentation/UserController.java

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -64,21 +64,4 @@ public UserInfoResponse getCurrentUserInfo(@Parameter(description = "Accesstoken
6464
return userService.getUserInfo(userId);
6565
}
6666

67-
@Operation(summary = "현재 유저 프로필 업데이트", description = "유저의 nickname, username, password(지난 비밀번호 검증 과정 존재) email, profileImageUrl 업데이트 기능(null 값으로 전송 시, 업데이트 X)")
68-
@PostMapping("/profile")
69-
public UserInfoResponse updateCurrentUserInfo(@Parameter(description = "Accesstoken을 입력해주세요.", required = true) @RequestHeader("Authorization") String token,
70-
@Valid @RequestBody UpdateUserRequest updateUserRequest) {
71-
if (token == null) {
72-
throw new InvalidTokenException();
73-
}
74-
75-
String jwt = token.startsWith("Bearer ") ? token.substring(7) : token;
76-
if (!jwtUtil.validateToken(jwt)) {
77-
throw new IllegalArgumentException("Invalid token");
78-
}
79-
Long userId = jwtUtil.extractId(jwt);
80-
81-
return userService.updateUserProfile(userId, updateUserRequest);
82-
}
83-
84-
}
67+
}

0 commit comments

Comments
 (0)