Skip to content

Commit ddcc137

Browse files
committed
⚰️ /me api 응답 수정
1 parent 67631e6 commit ddcc137

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

backend/src/main/java/io/f1/backend/domain/auth/dto/CurrentUserAndAdminResponse.java

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,19 @@
33
import io.f1.backend.domain.admin.dto.AdminPrincipal;
44
import io.f1.backend.domain.user.dto.UserPrincipal;
55

6-
public record CurrentUserAndAdminResponse(Long id, String name, String role, String providerId) {
6+
public record CurrentUserAndAdminResponse(Long id, String name, String role) {
77

88
public static CurrentUserAndAdminResponse from(UserPrincipal userPrincipal) {
99
return new CurrentUserAndAdminResponse(
1010
userPrincipal.getUserId(),
1111
userPrincipal.getUserNickname(),
12-
UserPrincipal.ROLE_USER,
13-
userPrincipal.getName());
12+
UserPrincipal.ROLE_USER);
1413
}
1514

1615
public static CurrentUserAndAdminResponse from(AdminPrincipal adminPrincipal) {
1716
return new CurrentUserAndAdminResponse(
1817
adminPrincipal.getAuthenticationAdmin().adminId(),
1918
adminPrincipal.getUsername(),
20-
AdminPrincipal.ROLE_ADMIN,
21-
null);
19+
AdminPrincipal.ROLE_ADMIN);
2220
}
2321
}

0 commit comments

Comments
 (0)