Skip to content

Commit

Permalink
refactor: 사용자 디바이스 토큰 제거 메서드 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
JJ503 committed Sep 21, 2023
1 parent b7ff40c commit 7779436
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
Expand Up @@ -144,7 +144,7 @@ public void withdrawal(

user.withdrawal();
blackListTokenService.registerBlackListToken(accessToken, refreshToken);
deviceTokenRepository.deleteById(user.getId());
deviceTokenRepository.deleteByUserId(user.getId());
provider.unlinkUserBy(user.getOauthId());
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,6 @@
public interface JpaDeviceTokenRepository extends JpaRepository<DeviceToken, Long> {

Optional<DeviceToken> findByUserId(final Long userId);

void deleteByUserId(Long id);
}

0 comments on commit 7779436

Please sign in to comment.