From 8be833d835d733e304190e9556f82e3d74238789 Mon Sep 17 00:00:00 2001 From: xhaktmchl Date: Thu, 24 Nov 2022 19:18:04 +0900 Subject: [PATCH] =?UTF-8?q?#5=20refactor:=20=EC=95=A0=ED=94=8C=20=EB=A1=9C?= =?UTF-8?q?=EA=B7=B8=EC=9D=B8=20res(TokenResponse)=20=EC=97=90=20name,=20e?= =?UTF-8?q?mail=20=ED=94=BC=EB=93=9C=20=EC=82=AD=EC=A0=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../yogit/server/applelogin/model/TokenResponse.java | 4 ---- .../server/applelogin/service/AppleServiceImpl.java | 3 --- .../server/utils/appletoken/AppleTokenService.java | 11 +++++++++++ 3 files changed, 11 insertions(+), 7 deletions(-) create mode 100644 server/src/main/java/com/yogit/server/utils/appletoken/AppleTokenService.java diff --git a/server/src/main/java/com/yogit/server/applelogin/model/TokenResponse.java b/server/src/main/java/com/yogit/server/applelogin/model/TokenResponse.java index 5a0bdf2..5388ffc 100644 --- a/server/src/main/java/com/yogit/server/applelogin/model/TokenResponse.java +++ b/server/src/main/java/com/yogit/server/applelogin/model/TokenResponse.java @@ -17,10 +17,6 @@ public class TokenResponse { private String refresh_token; private String token_type; - // 유저 엔티티 생성 후 res - private String name; - private String email; - //추가적인 응답 필드 private String userType; // ex)apple private Account account; diff --git a/server/src/main/java/com/yogit/server/applelogin/service/AppleServiceImpl.java b/server/src/main/java/com/yogit/server/applelogin/service/AppleServiceImpl.java index dee5d08..166a2b4 100644 --- a/server/src/main/java/com/yogit/server/applelogin/service/AppleServiceImpl.java +++ b/server/src/main/java/com/yogit/server/applelogin/service/AppleServiceImpl.java @@ -78,9 +78,6 @@ public TokenResponse requestCodeValidations(ServicesResponse serviceResponse, St // 유저 생성 CreateUserAppleReq createUserAppleReq = new CreateUserAppleReq(email, tokenResponse.getRefresh_token(),fullName, UserType.APPLE); saveduser = userService.createUserApple(createUserAppleReq); - - tokenResponse.setName(fullName); - tokenResponse.setEmail(email); } // 이미 refresh 토큰 있는 유저면 client_secret, refresh_token로 검증 else if (client_secret != null && code == null && refresh_token != null) { diff --git a/server/src/main/java/com/yogit/server/utils/appletoken/AppleTokenService.java b/server/src/main/java/com/yogit/server/utils/appletoken/AppleTokenService.java new file mode 100644 index 0000000..cf5f04b --- /dev/null +++ b/server/src/main/java/com/yogit/server/utils/appletoken/AppleTokenService.java @@ -0,0 +1,11 @@ +package com.yogit.server.utils.appletoken; + +import lombok.NoArgsConstructor; +import org.springframework.stereotype.Service; + +@Service +@NoArgsConstructor +public class AppleTokenService { + + +}