Open cso6005 opened 1 year ago
기존 코드
@Getter
public class AccountDetails extends User{
private final AccountEntity account;
// UserDetails
AccountDetails(AccountEntity account) {
super(account.getAccountEmail(), account.getAccountPassword(), List.of(new SimpleGrantedAuthority(account.getAccountType())));
this.account = account;
}
}
- 바꾼 코드
@Getter public class AccountDetails extends User{
private final AccountEntity account;
// UserDetails
AccountDetails(AccountEntity account) {
super(account.getAccountEmail(), account.getAccountPassword(), List.of(new SimpleGrantedAuthority("ROLE_" + account.getAccountType())));
this.account = account;
}
}
문제