Skip to content

Commit

Permalink
Merge pull request #121 from YogitTeam/feat/user-login
Browse files Browse the repository at this point in the history
#24 Feat : 애플 회원가입 및 로그인 res에 UserStatus.LOGIN 추가
  • Loading branch information
shinhn authored Jan 13, 2023
2 parents 6f5f992 + a0070fe commit a414dea
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package com.yogit.server.applelogin.model;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.yogit.server.user.entity.UserStatus;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
Expand All @@ -22,4 +23,5 @@ public class TokenResponse {
private Account account;
private Long userId;
private String userName;
private UserStatus userStatus;
}
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ else if (client_secret != null && code == null && refresh_token != null) {

tokenResponse.setAccount(new Account(serviceResponse.getState(), code, tokenResponse.getId_token(), user, serviceResponse.getIdentifier(), serviceResponse.getHasRequirementInfo()));
tokenResponse.setUserType(UserType.APPLE.toString());
tokenResponse.setUserStatus(UserStatus.LOGIN);

// userId 설정
if(refresh_token == null){
Expand All @@ -107,7 +108,6 @@ else if (client_secret != null && code == null && refresh_token != null) {
findUser.changeUserStatus(UserStatus.LOGIN);
}


return tokenResponse;
}

Expand Down

0 comments on commit a414dea

Please sign in to comment.